Package org.eclipse.emf.cdo.transaction
Interface CDOTransaction
- 
- All Superinterfaces:
- CDOBranchPoint,- CDOBranchProvider,- CDOChangeSetDataProvider,- CDOCommitHistory.Provider<CDOObject,CDOObjectHistory>,- CDOCommonTransaction,- CDOCommonView,- CDORevisionProvider,- CDOTimeProvider,- CDOUpdatable,- CDOUserTransaction,- CDOView,- org.eclipse.net4j.util.collection.Closeable,- IAdaptable,- org.eclipse.net4j.util.container.IContainer<CDOResourceNode>,- org.eclipse.net4j.util.event.INotifier,- org.eclipse.net4j.util.options.IOptionsContainer,- org.eclipse.net4j.util.properties.IPropertiesContainer
 - All Known Subinterfaces:
- InternalCDOTransaction
 - All Known Implementing Classes:
- CDOPushTransaction
 
 public interface CDOTransaction extends CDOView, CDOCommonTransaction, CDOUserTransaction, CDOChangeSetDataProvider A read-write view to the current (i.e. latest) state of the object graph in the repository.- Since:
- 2.0
- Author:
- Eike Stepper
- No Implement
- This interface is not intended to be implemented by clients.
- No Extend
- This interface is not intended to be extended by clients.
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Interface Description static classCDOTransaction.CommitResult<T>A value type that combines the result of a persistable computation and thecommit infoof the finaltransaction commit.static interfaceCDOTransaction.OptionsEncapsulates a set of notifyingtransactionconfiguration options.- 
Nested classes/interfaces inherited from interface org.eclipse.net4j.util.container.IContainerorg.eclipse.net4j.util.container.IContainer.Modifiable<E extends java.lang.Object>, org.eclipse.net4j.util.container.IContainer.Persistable<E extends java.lang.Object>, org.eclipse.net4j.util.container.IContainer.Persistence<E extends java.lang.Object>
 
- 
 - 
Field Summary- 
Fields inherited from interface org.eclipse.emf.cdo.common.branch.CDOBranchPointINVALID_DATE, UNSPECIFIED_DATE
 - 
Fields inherited from interface org.eclipse.emf.cdo.util.CDOUpdatableNO_TIMEOUT
 - 
Fields inherited from interface org.eclipse.emf.cdo.view.CDOViewPROP_TIME_MACHINE_DISABLED
 
- 
 - 
Method SummaryAll Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description voidaddTransactionHandler(CDOTransactionHandlerBase handler)CDOCommitInfocommit(java.lang.Runnable runnable, int attempts, IProgressMonitor monitor)CDOCommitInfocommit(java.lang.Runnable runnable, java.util.function.Predicate<java.lang.Long> retry, IProgressMonitor monitor)CDOCommitInfocommit(java.lang.Runnable runnable, org.eclipse.net4j.util.Predicate<java.lang.Long> retry, IProgressMonitor monitor)Deprecated.<T> CDOTransaction.CommitResult<T>commit(java.util.concurrent.Callable<T> callable, int attempts, IProgressMonitor monitor)<T> CDOTransaction.CommitResult<T>commit(java.util.concurrent.Callable<T> callable, java.util.function.Predicate<java.lang.Long> retry, IProgressMonitor monitor)<T> CDOTransaction.CommitResult<T>commit(java.util.concurrent.Callable<T> callable, org.eclipse.net4j.util.Predicate<java.lang.Long> retry, IProgressMonitor monitor)Deprecated.CDOBinaryResourcecreateBinaryResource(java.lang.String path)CDOQuerycreateQuery(java.lang.String language, java.lang.String queryString, boolean considerDirtyState)CDOQuerycreateQuery(java.lang.String language, java.lang.String queryString, java.lang.Object context, boolean considerDirtyState)CDOResourcecreateResource(java.lang.String path)CDOResourceFoldercreateResourceFolder(java.lang.String path)CDOTextResourcecreateTextResource(java.lang.String path)CDOSavepoint[]exportChanges(java.io.OutputStream out)java.lang.StringgetCommitComment()Returns the comment to be used in the next commit operation.java.util.Set<? extends org.eclipse.emf.ecore.EObject>getCommittables()java.util.Set<CDOObject>getConflicts()Returns the set of objects that are conflicting with remote modifications or an empty set ifhasConflict()returnsfalse.java.util.Map<CDOID,CDOObject>getDetachedObjects()java.util.Map<CDOID,CDOObject>getDirtyObjects()CDOSavepointgetFirstSavepoint()longgetLastCommitTime()CDOSavepointgetLastSavepoint()java.util.Map<CDOID,CDOObject>getNewObjects()CDOBinaryResourcegetOrCreateBinaryResource(java.lang.String path)CDOResourcegetOrCreateResource(java.lang.String path)CDOResourceFoldergetOrCreateResourceFolder(java.lang.String path)CDOTextResourcegetOrCreateTextResource(java.lang.String path)java.util.Map<CDOID,CDORevisionDelta>getRevisionDeltas()CDOTransactionHandler[]getTransactionHandlers()CDOTransactionHandler1[]getTransactionHandlers1()CDOTransactionHandler2[]getTransactionHandlers2()booleanhasConflict()Returnstrueif this transaction contains local modifications that are conflicting with remote modifications,falseotherwise.CDOSavepoint[]importChanges(java.io.InputStream in, boolean reconstructSavepoints)booleanisDirty()Returnstrueif this transaction is not closed and contains uncommitted changes,falseotherwise.CDOChangeSetDatamerge(CDOBranchPoint source, CDOBranchPoint sourceBase, CDOBranchPoint targetBase, CDOMerger merger)Merges the changes between the given source base point and the given source point into this transaction.CDOChangeSetDatamerge(CDOBranchPoint source, CDOBranchPoint sourceBase, CDOMerger merger)Merges the changes between the given source base point and the given source point into this transaction.CDOChangeSetDatamerge(CDOBranchPoint source, CDOMerger merger)Merges the changes from the given source point into this transaction and possibly considers previous merges from thatbranchby inspecting themerge sourceinformation of thecommit history.CDOChangeSetDatamerge(CDOBranch source, CDOMerger merger)Merges the changes from the given source branch into this transaction and possibly considers previous merges from that branch by inspecting themerge sourceinformation of thecommit history.CDOTransaction.Optionsoptions()Returns theoptionsof this view.voidremoveTransactionHandler(CDOTransactionHandlerBase handler)CDOChangeSetDatarevertTo(CDOBranchPoint branchPoint)voidsetCommitComment(java.lang.String comment)Sets the comment to be used in the next commit operation.voidsetCommittables(java.util.Set<? extends org.eclipse.emf.ecore.EObject> committables)CDOSavepointsetSavepoint()Creates a save point in theCDOTransactionthat can be used to roll back a part of the transaction- 
Methods inherited from interface org.eclipse.emf.cdo.common.branch.CDOBranchPointgetBranch, getTimeStamp
 - 
Methods inherited from interface org.eclipse.emf.cdo.common.commit.CDOChangeSetDataProvidergetChangeSetData
 - 
Methods inherited from interface org.eclipse.emf.cdo.common.commit.CDOCommitHistory.ProvidergetHistory, getHistory
 - 
Methods inherited from interface org.eclipse.emf.cdo.common.CDOCommonViewgetDurableLockingID, getLockOwner, getSessionID, getViewID, isDurableView, isHistorical, isReadOnly
 - 
Methods inherited from interface org.eclipse.emf.cdo.common.revision.CDORevisionProvidergetRevision
 - 
Methods inherited from interface org.eclipse.emf.cdo.util.CDOUpdatablegetLastUpdateTime, runAfterUpdate, waitForUpdate, waitForUpdate
 - 
Methods inherited from interface org.eclipse.emf.cdo.transaction.CDOUserTransactioncommit, commit, rollback
 - 
Methods inherited from interface org.eclipse.emf.cdo.view.CDOViewaddObjectHandler, addRegistrationHandler, compareRevisions, createQuery, createQuery, createResourceURI, disableDurableLocking, enableDurableLocking, enableDurableLocking, getBinaryResource, getLockStates, getLockStatesOfObjects, getObject, getObject, getObject, getObjectHandlers, getObjects, getProvider, getRegistrationHandlers, getResource, getResource, getResourceFolder, getResourceNode, getResourceSet, getRootResource, getSession, getTextResource, getUnitManager, getURIHandler, getViewLock, getViewSet, hasResource, isInvalidating, isInvalidationRunnerActive, isLegacyModeEnabled, isObjectRegistered, lockObjects, lockObjects, queryInstances, queryInstancesAsync, queryInstancesAsync, queryResources, queryResourcesAsync, queryXRefs, queryXRefs, queryXRefsAsync, refreshLockStates, reload, removeObjectHandler, removeRegistrationHandler, setBranch, setBranch, setBranchPoint, setBranchPoint, setBranchPoint, setBranchPoint, setResourcePathCache, setTimeStamp, setTimeStamp, syncExec, syncExec, unlockObjects, unlockObjects, unlockObjects
 - 
Methods inherited from interface org.eclipse.core.runtime.IAdaptablegetAdapter
 
- 
 
- 
- 
- 
Method Detail- 
isDirtyboolean isDirty() Returnstrueif this transaction is not closed and contains uncommitted changes,falseotherwise.
 - 
hasConflictboolean hasConflict() Returnstrueif this transaction contains local modifications that are conflicting with remote modifications,falseotherwise.- Specified by:
- hasConflictin interface- CDOView
- See Also:
- hasConflict()
 
 - 
getConflictsjava.util.Set<CDOObject> getConflicts() Returns the set of objects that are conflicting with remote modifications or an empty set ifhasConflict()returnsfalse.
 - 
revertToCDOChangeSetData revertTo(CDOBranchPoint branchPoint) - Since:
- 4.15
 
 - 
mergeCDOChangeSetData merge(CDOBranch source, CDOMerger merger) Merges the changes from the given source branch into this transaction and possibly considers previous merges from that branch by inspecting themerge sourceinformation of thecommit history.- Since:
- 4.6
- See Also:
- merge(CDOBranchPoint, CDOMerger)
 
 - 
mergeCDOChangeSetData merge(CDOBranchPoint source, CDOMerger merger) Merges the changes from the given source point into this transaction and possibly considers previous merges from thatbranchby inspecting themerge sourceinformation of thecommit history.- Since:
- 3.0
 
 - 
mergeCDOChangeSetData merge(CDOBranchPoint source, CDOBranchPoint sourceBase, CDOMerger merger) Merges the changes between the given source base point and the given source point into this transaction.Warning: If the branch of this transaction already contains merges from the given source point range (i.e., if this merge is a "remerge") this method will likely fail. One of the following methods should be used instead: - Since:
- 4.0
 
 - 
mergeCDOChangeSetData merge(CDOBranchPoint source, CDOBranchPoint sourceBase, CDOBranchPoint targetBase, CDOMerger merger) Merges the changes between the given source base point and the given source point into this transaction.When specifying an adequate target base point this method is able to perform a proper "remerge". - Since:
- 4.6
- See Also:
- merge(CDOBranchPoint, CDOMerger),- merge(CDOBranch, CDOMerger)
 
 - 
createResourceFolderCDOResourceFolder createResourceFolder(java.lang.String path) throws CDOResourceNodeNotFoundException - Throws:
- CDOResourceNodeNotFoundException
- Since:
- 4.0
 
 - 
getOrCreateResourceFolderCDOResourceFolder getOrCreateResourceFolder(java.lang.String path) - Since:
- 4.0
 
 - 
createResourceCDOResource createResource(java.lang.String path) - See Also:
- ResourceSet.createResource(URI)
 
 - 
getOrCreateResourceCDOResource getOrCreateResource(java.lang.String path) 
 - 
createTextResourceCDOTextResource createTextResource(java.lang.String path) - Since:
- 4.2
 
 - 
getOrCreateTextResourceCDOTextResource getOrCreateTextResource(java.lang.String path) - Since:
- 4.2
 
 - 
createBinaryResourceCDOBinaryResource createBinaryResource(java.lang.String path) - Since:
- 4.2
 
 - 
getOrCreateBinaryResourceCDOBinaryResource getOrCreateBinaryResource(java.lang.String path) - Since:
- 4.2
 
 - 
addTransactionHandlervoid addTransactionHandler(CDOTransactionHandlerBase handler) - Since:
- 4.0
 
 - 
removeTransactionHandlervoid removeTransactionHandler(CDOTransactionHandlerBase handler) - Since:
- 4.0
 
 - 
getTransactionHandlersCDOTransactionHandler[] getTransactionHandlers() - Since:
- 3.0
 
 - 
getTransactionHandlers1CDOTransactionHandler1[] getTransactionHandlers1() - Since:
- 4.0
 
 - 
getTransactionHandlers2CDOTransactionHandler2[] getTransactionHandlers2() - Since:
- 4.0
 
 - 
setSavepointCDOSavepoint setSavepoint() Description copied from interface:CDOUserTransactionCreates a save point in theCDOTransactionthat can be used to roll back a part of the transactionSave points do not involve the server side, everything is done on the client side. - Specified by:
- setSavepointin interface- CDOUserTransaction
- Since:
- 3.0
 
 - 
getFirstSavepointCDOSavepoint getFirstSavepoint() - Since:
- 4.1
 
 - 
getLastSavepointCDOSavepoint getLastSavepoint() - Specified by:
- getLastSavepointin interface- CDOUserTransaction
- Since:
- 3.0
 
 - 
getRevisionDeltasjava.util.Map<CDOID,CDORevisionDelta> getRevisionDeltas() 
 - 
exportChangesCDOSavepoint[] exportChanges(java.io.OutputStream out) throws java.io.IOException - Throws:
- java.io.IOException
- Since:
- 3.0
 
 - 
importChangesCDOSavepoint[] importChanges(java.io.InputStream in, boolean reconstructSavepoints) throws java.io.IOException - Throws:
- java.io.IOException
- Since:
- 3.0
 
 - 
getLastCommitTimelong getLastCommitTime() 
 - 
getCommitCommentjava.lang.String getCommitComment() Returns the comment to be used in the next commit operation.- Since:
- 3.0
- See Also:
- CDOCommitInfo.getComment()
 
 - 
setCommitCommentvoid setCommitComment(java.lang.String comment) Sets the comment to be used in the next commit operation.- Since:
- 3.0
- See Also:
- CDOCommitInfo.getComment()
 
 - 
setCommittablesvoid setCommittables(java.util.Set<? extends org.eclipse.emf.ecore.EObject> committables) - Since:
- 4.0
 
 - 
getCommittablesjava.util.Set<? extends org.eclipse.emf.ecore.EObject> getCommittables() - Since:
- 4.0
 
 - 
createQueryCDOQuery createQuery(java.lang.String language, java.lang.String queryString, boolean considerDirtyState) - Since:
- 4.0
 
 - 
createQueryCDOQuery createQuery(java.lang.String language, java.lang.String queryString, java.lang.Object context, boolean considerDirtyState) - Since:
- 4.0
 
 - 
commit@Deprecated <T> CDOTransaction.CommitResult<T> commit(java.util.concurrent.Callable<T> callable, org.eclipse.net4j.util.Predicate<java.lang.Long> retry, IProgressMonitor monitor) throws ConcurrentAccessException, CommitException, java.lang.Exception Deprecated.- Throws:
- ConcurrentAccessException
- CommitException
- java.lang.Exception
- Since:
- 4.8
 
 - 
commit<T> CDOTransaction.CommitResult<T> commit(java.util.concurrent.Callable<T> callable, java.util.function.Predicate<java.lang.Long> retry, IProgressMonitor monitor) throws ConcurrentAccessException, CommitException, java.lang.Exception - Throws:
- ConcurrentAccessException
- CommitException
- java.lang.Exception
- Since:
- 4.9
 
 - 
commit<T> CDOTransaction.CommitResult<T> commit(java.util.concurrent.Callable<T> callable, int attempts, IProgressMonitor monitor) throws ConcurrentAccessException, CommitException, java.lang.Exception - Throws:
- ConcurrentAccessException
- CommitException
- java.lang.Exception
- Since:
- 4.8
 
 - 
commit@Deprecated CDOCommitInfo commit(java.lang.Runnable runnable, org.eclipse.net4j.util.Predicate<java.lang.Long> retry, IProgressMonitor monitor) throws ConcurrentAccessException, CommitException Deprecated.- Throws:
- ConcurrentAccessException
- CommitException
- Since:
- 4.8
 
 - 
commitCDOCommitInfo commit(java.lang.Runnable runnable, java.util.function.Predicate<java.lang.Long> retry, IProgressMonitor monitor) throws ConcurrentAccessException, CommitException - Throws:
- ConcurrentAccessException
- CommitException
- Since:
- 4.9
 
 - 
commitCDOCommitInfo commit(java.lang.Runnable runnable, int attempts, IProgressMonitor monitor) throws ConcurrentAccessException, CommitException - Throws:
- ConcurrentAccessException
- CommitException
- Since:
- 4.8
 
 - 
optionsCDOTransaction.Options options() Description copied from interface:CDOCommonViewReturns theoptionsof this view.- Specified by:
- optionsin interface- CDOCommonView
- Specified by:
- optionsin interface- CDOView
- Specified by:
- optionsin interface- org.eclipse.net4j.util.options.IOptionsContainer
 
 
- 
 
-