Class XidImpl2
- java.lang.Object
-
- org.apache.geronimo.transaction.log.XidImpl2
-
- All Implemented Interfaces:
Serializable,Xid
public class XidImpl2 extends Object implements Xid, Serializable
Unique id for a transaction. This implementation is backed by a single byte buffer so can do less copying than one backed by several byte buffers for the different components.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from interface javax.transaction.xa.Xid
MAXBQUALSIZE, MAXGTRIDSIZE
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)byte[]getBranchQualifier()intgetFormatId()byte[]getGlobalTransactionId()ObjectgetKey()inthashCode()voidsetKey(Object key)StringtoString()
-
-
-
Constructor Detail
-
XidImpl2
public XidImpl2(byte[] globalId)
Constructor taking a global id (for the main transaction)- Parameters:
globalId- the global transaction id
-
XidImpl2
public XidImpl2(Xid global, byte[] branch)
Constructor for a branch id- Parameters:
global- the xid of the global transaction this branch belongs tobranch- the branch id
-
XidImpl2
public XidImpl2(int formatId, byte[] globalId, byte[] branch)
-
-
Method Detail
-
getFormatId
public int getFormatId()
- Specified by:
getFormatIdin interfaceXid
-
getGlobalTransactionId
public byte[] getGlobalTransactionId()
- Specified by:
getGlobalTransactionIdin interfaceXid
-
getBranchQualifier
public byte[] getBranchQualifier()
- Specified by:
getBranchQualifierin interfaceXid
-
setKey
public void setKey(Object key)
-
getKey
public Object getKey()
-
-