public interface TxInvocationContext extends InvocationContext
Modifier and Type | Method and Description |
---|---|
void |
addAffectedKey(Object key) |
void |
addAllAffectedKeys(Collection<Object> keys)
Registers a new participant with the transaction.
|
Set<Object> |
getAffectedKeys()
Returns the set of keys that are affected by this transaction.
|
CacheTransaction |
getCacheTransaction() |
GlobalTransaction |
getGlobalTransaction()
Returns the id of the transaction associated with the current call.
|
List<WriteCommand> |
getModifications()
Returns the modifications performed in the scope of the current transaction.
|
Transaction |
getTransaction()
Returns the tx associated with the current thread.
|
boolean |
hasModifications()
Checks if there are modifications performed within the tx's scope.
|
boolean |
isImplicitTransaction() |
boolean |
isTransactionValid() |
void |
setImplicitTransaction(boolean implicit)
Marks this transaction as implicit; implicit transactions are started for transactional caches that have the autoCommit enabled.
|
boolean |
skipTransactionCompleteCheck() |
void |
skipTransactionCompleteCheck(boolean skip) |
addLockedKey, clearLockedKeys, clone, getClassLoader, getLockedKeys, getLockOwner, getOrigin, hasLockedKey, isEntryRemovedInContext, isInTxScope, isOriginLocal, replaceValue, setClassLoader
getLookedUpEntries, lookupEntry, putLookedUpEntry, removeLookedUpEntry
boolean hasModifications()
Set<Object> getAffectedKeys()
GlobalTransaction getGlobalTransaction()
List<WriteCommand> getModifications()
Transaction getTransaction()
InvocationContext.isOriginLocal()
, as Transaction
are not propagated from the node where tx was
started.IllegalStateException
- if the call is performed from a InvocationContext.isOriginLocal()
==false context.void addAllAffectedKeys(Collection<Object> keys)
void addAffectedKey(Object key)
boolean isTransactionValid()
void setImplicitTransaction(boolean implicit)
boolean isImplicitTransaction()
CacheTransaction getCacheTransaction()
void skipTransactionCompleteCheck(boolean skip)
boolean skipTransactionCompleteCheck()
Copyright © 2014 JBoss, a division of Red Hat. All Rights Reserved.