|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectbitronix.tm.resource.common.AbstractXAStatefulHolder
bitronix.tm.resource.common.AbstractXAResourceHolder
public abstract class AbstractXAResourceHolder
Implementation of all services required by a XAResourceHolder. This class keeps a list of all
XAResourceHolderStates of the XAResourceHolder plus the currently active one. There is
one per transaction in which this XAResourceHolder is enlisted plus all the suspended transactions in which
it is enlisted as well.
| Field Summary |
|---|
| Fields inherited from interface bitronix.tm.resource.common.XAStatefulHolder |
|---|
STATE_ACCESSIBLE, STATE_CLOSED, STATE_IN_POOL, STATE_NOT_ACCESSIBLE |
| Constructor Summary | |
|---|---|
AbstractXAResourceHolder()
|
|
| Method Summary | |
|---|---|
Set |
getXAResourceHolderStateGtrids()
Simple helper method which returns a set of GTRIDs of transactions in which this resource is enlisted. |
Map |
getXAResourceHolderStatesForGtrid(Uid gtrid)
Get all the XAResourceHolderStates of this wrapped resource for a specific GTRID. |
boolean |
hasStateForXAResource(XAResourceHolder xaResourceHolder)
Check if this XAResourceHolder contains a state for a specific XAResourceHolder. |
boolean |
isParticipatingInActiveGlobalTransaction()
If this method returns false, then local transaction calls like Connection.commit() can be made. |
void |
putXAResourceHolderState(BitronixXid xid,
XAResourceHolderState xaResourceHolderState)
Add a XAResourceHolderState of this wrapped resource. |
void |
removeXAResourceHolderState(BitronixXid xid)
Remove all states related to a specific Xid from this wrapped resource. |
| Methods inherited from class bitronix.tm.resource.common.AbstractXAStatefulHolder |
|---|
addStateChangeEventListener, getState, removeStateChangeEventListener, setState |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface bitronix.tm.resource.common.XAResourceHolder |
|---|
getResourceBean, getXAResource |
| Methods inherited from interface bitronix.tm.resource.common.XAStatefulHolder |
|---|
addStateChangeEventListener, close, getConnectionHandle, getLastReleaseDate, getState, getXAResourceHolders, removeStateChangeEventListener, setState |
| Constructor Detail |
|---|
public AbstractXAResourceHolder()
| Method Detail |
|---|
public Map getXAResourceHolderStatesForGtrid(Uid gtrid)
XAResourceHolderXAResourceHolderStates of this wrapped resource for a specific GTRID.
The returned Map is guaranteed to return states in order they were added when its values are iterated.
getXAResourceHolderStatesForGtrid in interface XAResourceHoldergtrid - the GTRID of the transaction state to add.
XAResourceHolderState.
public void putXAResourceHolderState(BitronixXid xid,
XAResourceHolderState xaResourceHolderState)
XAResourceHolderXAResourceHolderState of this wrapped resource.
putXAResourceHolderState in interface XAResourceHolderxid - the Xid of the transaction state to add.xaResourceHolderState - the XAResourceHolderState to set.public void removeXAResourceHolderState(BitronixXid xid)
XAResourceHolder
removeXAResourceHolderState in interface XAResourceHolderxid - the Xid of the transaction state to remove.public boolean hasStateForXAResource(XAResourceHolder xaResourceHolder)
XAResourceHolderXAResourceHolder contains a state for a specific XAResourceHolder.
In other words: has the XAResourceHolder's XAResource been enlisted in some transaction ?
hasStateForXAResource in interface XAResourceHolderxaResourceHolder - the XAResourceHolder to look for.
XAResourceHolder is enlisted in some transaction, false otherwise.public boolean isParticipatingInActiveGlobalTransaction()
public Set getXAResourceHolderStateGtrids()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||