| java.lang.Object org.geotools.data.AutoCommitTransaction
AutoCommitTransaction | class AutoCommitTransaction implements Transaction(Code) | | This is used to represent the absense of a Transaction and the use of
AutoCommit.
This class serves as the implementation of the constant Transaction.NONE.
It is a NullObject and we feel no need to make this class public.
|
Method Summary | |
public void | addAuthorization(String authID) Authorization IDs are not stored by AutoCommit. | public void | close() Implements a NOP since AUTO_COMMIT does not maintain State. | public void | commit() Implemented as a NOP since this Transaction always commits. | public Set | getAuthorizations() Authorization IDs are not stored by AutoCommit. | public Object | getProperty(Object key) AutoCommit does not save State. | public State | getState(Object key) I am not sure should AutoCommit be able to save sate?
While symetry would be good, state should be commited not stored for
later. | public void | putProperty(Object key, Object value) Implementation of addProperty. | public void | putState(Object key, State state) AutoCommit does not save State. | public void | removeState(Object key) AutoCommit does not save State. | public void | rollback() Auto commit mode cannot support the rollback opperation. |
addAuthorization | public void addAuthorization(String authID) throws IOException(Code) | | Authorization IDs are not stored by AutoCommit.
Authorization IDs are only stored for the duration of a Transaction.
Parameters: authID - Authorization ID throws: IOException - If set authorization fails |
close | public void close()(Code) | | Implements a NOP since AUTO_COMMIT does not maintain State.
|
commit | public void commit()(Code) | | Implemented as a NOP since this Transaction always commits.
This allows the following workflow:
Transaction t = roads.getTransaction();
try{
roads.addFeatures( features );
roads.getTransaction().commit();
}
catch( IOException erp ){
//something went wrong;
roads.getTransaction().rollback();
}
|
getAuthorizations | public Set getAuthorizations()(Code) | | Authorization IDs are not stored by AutoCommit.
Authorization IDs are only stored for the duration of a Transaction.
Set of authorizations throws: UnsupportedOperationException - AUTO_COMMIT does not support this |
getProperty | public Object getProperty(Object key)(Code) | | AutoCommit does not save State.
While symetry would be good, state should be commited not stored for
later.
Parameters: key - Key that is not used to Store Property Property associated with key, or null throws: UnsupportedOperationException - AutoCommit does not support State |
getState | public State getState(Object key)(Code) | | I am not sure should AutoCommit be able to save sate?
While symetry would be good, state should be commited not stored for
later.
Parameters: key - Key used to retrieve State State earlier provided with putState throws: UnsupportedOperationException - As Autocommit does not supportState |
putState | public void putState(Object key, State state)(Code) | | AutoCommit does not save State.
While symetry would be good, state should be commited not stored for
later.
Parameters: key - Key that is not used to Store State Parameters: state - State we are not going to externalize throws: UnsupportedOperationException - AutoCommit does not support State |
removeState | public void removeState(Object key)(Code) | | AutoCommit does not save State.
While symetry would be good, state should be commited not stored for
later.
Parameters: key - Key that is not used to Store State throws: UnsupportedOperationException - AutoCommit does not support State |
rollback | public void rollback() throws IOException(Code) | | Auto commit mode cannot support the rollback opperation.
throws: IOException - if Rollback fails |
|
|