|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.infinispan.context.InvocationContextContainerImpl
public class InvocationContextContainerImpl
Default implementation for InvocationContextContainer.
| Constructor Summary | |
|---|---|
InvocationContextContainerImpl()
|
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public InvocationContextContainerImpl()
| Method Detail |
|---|
public void init(TransactionManager tm,
TransactionTable transactionTable)
public InvocationContext createInvocationContext()
InvocationContextContainerTxInvocationContext. Otherwise it will return an
NonTxInvocationContext. Either way, both context will be
marked as local, i.e. InvocationContext.isOriginLocal() will be true. The context is
also associated with the current thread, so further calls to InvocationContextContainer.getInvocationContext()
will return same instance.
createInvocationContext in interface InvocationContextContainerpublic InvocationContext createInvocationContext(Transaction tx)
InvocationContextContainer
createInvocationContext in interface InvocationContextContainerpublic LocalTxInvocationContext createTxInvocationContext()
InvocationContextContainerLocalTxInvocationContext. The context is also
associated with the current thread, so further calls to InvocationContextContainer.getInvocationContext() will
return same instance.
createTxInvocationContext in interface InvocationContextContainerpublic RemoteTxInvocationContext createRemoteTxInvocationContext(Address origin)
InvocationContextContainerRemoteTxInvocationContext. The context is also
associated with the current thread, so further calls to InvocationContextContainer.getInvocationContext() will
return same instance.
createRemoteTxInvocationContext in interface InvocationContextContainerorigin - the origin of the command, or null if localpublic NonTxInvocationContext createNonTxInvocationContext()
InvocationContextContainerNonTxInvocationContext with the
NonTxInvocationContext.isOriginLocal() returning true.
createNonTxInvocationContext in interface InvocationContextContainer
public InvocationContext createRemoteInvocationContextForCommand(VisitableCommand cacheCommand,
Address origin)
InvocationContextContainer#createRemoteInvocationContext(), but returning the flags to the context from
the Command if any Flag was set.
createRemoteInvocationContextForCommand in interface InvocationContextContainerorigin - the origin of the command, or null if localpublic NonTxInvocationContext createRemoteInvocationContext(Address origin)
InvocationContextContainerNonTxInvocationContext whose
NonTxInvocationContext.isOriginLocal() flag will be true.
The context is also associated with the current thread, so further calls to
InvocationContextContainer.getInvocationContext() will return same instance.
createRemoteInvocationContext in interface InvocationContextContainerorigin - the origin of the command, or null if localpublic InvocationContext getInvocationContext()
InvocationContextContainerInvocationContext that is currently associated with the calling thread.
Important: implementations of this method is most likely expensive (ThreadLocal.get), it is
recommended to cache the result of this method rather than repeating the call.
getInvocationContext in interface InvocationContextContainerpublic InvocationContext suspend()
InvocationContextContainer
suspend in interface InvocationContextContainerpublic void resume(InvocationContext ctxt)
InvocationContextContainerInvocationContext with the calling thread.
resume in interface InvocationContextContainer
|
--> | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||