|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.amazon.carbonado.spi.AbstractRepositoryBuilder
public abstract class AbstractRepositoryBuilder
Abstract builder class for opening repositories.
| Constructor Summary | |
|---|---|
protected |
AbstractRepositoryBuilder()
|
| Method Summary | |
|---|---|
boolean |
addTriggerFactory(TriggerFactory factory)
Optionally add a TriggerFactory which will be called upon to create an initial trigger for each Storable type that the Repository supports. |
void |
assertReady()
Throw a configuration exception if the configuration is not filled out sufficiently and correctly such that a repository could be instantiated from it. |
Repository |
build()
Builds a repository instance. |
void |
errorCheck(Collection<String> messages)
This method is called by assertReady, and subclasses must override to perform custom checks. |
Iterable<TriggerFactory> |
getTriggerFactories()
Returns all the TriggerFactories which were added. |
boolean |
removeTriggerFactory(TriggerFactory factory)
Remove a TriggerFactory which was added earlier. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.amazon.carbonado.RepositoryBuilder |
|---|
build, getName, isMaster, setMaster, setName |
| Constructor Detail |
|---|
protected AbstractRepositoryBuilder()
| Method Detail |
|---|
public Repository build()
throws ConfigurationException,
RepositoryException
RepositoryBuilder
build in interface RepositoryBuilderConfigurationException - if there is a problem in the builder's configuration
RepositoryException - if there is a general problem opening the repositorypublic boolean addTriggerFactory(TriggerFactory factory)
RepositoryBuilder
addTriggerFactory in interface RepositoryBuilderpublic boolean removeTriggerFactory(TriggerFactory factory)
RepositoryBuilder
removeTriggerFactory in interface RepositoryBuilderpublic Iterable<TriggerFactory> getTriggerFactories()
RepositoryBuilder
getTriggerFactories in interface RepositoryBuilder
public final void assertReady()
throws ConfigurationException
ConfigurationException
public void errorCheck(Collection<String> messages)
throws ConfigurationException
super.errorCheck as well.
messages - add any error messages to this list
ConfigurationException - if error checking indirectly caused
another exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||