public abstract class AbstractDBResourceBlocker extends AbstractResource implements DBResource
lock, multiResourcelock| Modifier | Constructor and Description |
|---|---|
protected |
AbstractDBResourceBlocker(AbstractDBResourceParameters parameters)
Default constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
connect()
Establish connection to data base
|
protected abstract void |
connectToDB()
|
protected boolean |
equals(java.lang.Comparable v1,
java.lang.Comparable v2) |
java.lang.Object |
get()
Return a connection to the data base.
|
java.lang.Object |
getConnection()
Return a connection to the data base.
|
protected abstract java.lang.Object |
getTheConnection()
final implementation method to get a connection to data base
Called from connect()This method is called with the connection establish |
boolean |
isThis(ResourceParameters parameters)
Check if parameters is the same for this resource.
|
addConsumer, addObserver, addObservers, closeRequest, deleteObserver, deleteObservers, execute, executeBegins, executeEnds, getConsumerAt, getConsumersCount, getData, getLastTimeOpen, getLastTimeUsed, getName, getParameters, inUse, isOpen, notifyChanges, notifyClose, notifyDispose, notifyObserver, notifyOpen, openCount, performExecution, prepare, prepare, removeConsumer, setData, updateLastTimeOpen, updateLastTimeUsedclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitisConnectedaddConsumer, closeRequest, execute, getConsumersCount, getData, getLastTimeOpen, getLastTimeUsed, getName, getParameters, inUse, isOpen, openCount, removeConsumer, setDataprotected AbstractDBResourceBlocker(AbstractDBResourceParameters parameters) throws InitializeException
parameters - InitializeExceptionpublic java.lang.Object get()
throws AccessResourceException
get in interface Resourceget in class AbstractResourceAccessResourceException - if there is an error while accessing the resourcepublic java.lang.Object getConnection()
throws AccessResourceException
AccessResourceExceptionget()public final void connect()
throws DataException
DataExceptionpublic boolean isThis(ResourceParameters parameters) throws ResourceException
isThis in interface ResourceProviderResourceExceptionResourceProvider.isThis(ResourceParameters)protected boolean equals(java.lang.Comparable v1,
java.lang.Comparable v2)
protected abstract void connectToDB()
throws DataException
DataExceptionprotected abstract java.lang.Object getTheConnection()
throws DataException
connect()DataException