|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jplate.tabular.impl.defaults.DefaultRepo
public class DefaultRepo
Default repo implementation.
Modifications: $Date: 2008-12-02 12:32:45 -0500 (Tue, 02 Dec 2008) $ $Revision: 479 $ $Author: sfloess $ $HeadURL: https://jplate.svn.sourceforge.net/svnroot/jplate/trunk/src/dev/java/org/jplate/tabular/impl/defaults/DefaultRepo.java $
Field Summary | |
---|---|
private org.apache.commons.logging.Log |
_log
Used for logging. |
private java.lang.String |
_repoName
The name of the repo. |
private TableFactoryIfc |
_tableFactory
Used to create tables. |
private java.util.List<TableIfc> |
_tableList
Holds all tables that belong to a repo. |
static java.lang.String |
DEFAULT_REPO_NAME
Default repo name. |
Constructor Summary | |
---|---|
DefaultRepo()
Default constructor. |
|
DefaultRepo(ListFactoryIfc<TableIfc> listFactory)
This constructor uses listFactory to create a
List to hold tables that are logically part of a repo. |
|
DefaultRepo(java.lang.String repoName)
This constructor sets the repo name and uses a UnsynchronizedLinkedListFactory as
the list factory. |
|
DefaultRepo(TableFactoryIfc tableFactory,
ListFactoryIfc<TableIfc> listFactory,
java.lang.String repoName)
This constructor sets the repo name and uses listFactory to
create a List to hold tables that are logically part of
a repo. |
Method Summary | |
---|---|
void |
addTable(TableIfc table)
Add table . |
void |
close()
This method will close a repo. |
TableIfc |
createTable()
|
java.lang.String |
getRepoName()
Return the repo name, |
java.util.List<TableIfc> |
getTables()
Return the collection of tables. |
void |
open()
This method will open an existing repo. |
boolean |
removeTable(TableIfc table)
Remove table . |
void |
removeTables()
This method will force the removal of all tables. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String DEFAULT_REPO_NAME
private final transient org.apache.commons.logging.Log _log
private TableFactoryIfc _tableFactory
private final java.util.List<TableIfc> _tableList
private final java.lang.String _repoName
Constructor Detail |
---|
public DefaultRepo(TableFactoryIfc tableFactory, ListFactoryIfc<TableIfc> listFactory, java.lang.String repoName)
listFactory
to
create a List
to hold tables that are logically part of
a repo.
listFactory
- Used to create a list to hold associated tables.repoName
- The name of this repo.public DefaultRepo(ListFactoryIfc<TableIfc> listFactory)
listFactory
to create a
List
to hold tables that are logically part of a repo. The
repo name is set to DEFAULT_REPO_NAME
listFactory
- Used to create a list to hold associated tables.public DefaultRepo(java.lang.String repoName)
UnsynchronizedLinkedListFactory
as
the list factory.
repoName
- The name of this repo.public DefaultRepo()
DEFAULT_REPO_NAME
and
uses a
UnsynchronizedLinkedListFactory
as
the list factory.
Method Detail |
---|
public TableIfc createTable()
createTable
in interface RepoIfc
public java.lang.String getRepoName()
getRepoName
in interface RepoIfc
public void open() throws OpenException
open
in interface RepoIfc
OpenException
- If a problem arose opening the repo.public void close() throws CloseException
close
in interface RepoIfc
CloseException
- If a problem arose closing the repo.public void addTable(TableIfc table) throws AddException
table
.
addTable
in interface RepoIfc
table
- The table to Add.
AddException
- if any issues arise adding table
.public void removeTables() throws RemoveException
removeTables
in interface RepoIfc
RemoveException
- if a problem arose removing all tables.public boolean removeTable(TableIfc table) throws RemoveException
table
.
removeTable
in interface RepoIfc
table
- The table to remove.
RemoveException
- if any issues arise removing table
.public java.util.List<TableIfc> getTables()
getTables
in interface RepoIfc
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |