tyrex.tm.xid

Class BaseXid

public abstract class BaseXid extends Object implements Xid

Base implementation for all xids used by Tyrex (local, global, branch and external). All xids have a string representation in the form xid:-[][-].

Version: $Revision: 1.2 $

Author: Assaf Arkin

Field Summary
protected static byte[]EMPTY_ARRAY
The default branch is always an empty byte array.
static intFORMAT_ID
Format identifier for all internal Xids or newly created Xids.
protected static char[]HEX_DIGITS
Efficient mapping from 4 bit value to lower case hexadecimal digit.
static StringXID_PREFIX
Prefix for textual identifier.
protected String_string
The textual representation of the transaction identifier.
Method Summary
protected static char[]createPrefix(int formatId)
inthashCode()
abstract XidnewBranch()
Creates a new transaction branch.
StringtoString()

Field Detail

EMPTY_ARRAY

protected static final byte[] EMPTY_ARRAY
The default branch is always an empty byte array.

FORMAT_ID

public static final int FORMAT_ID
Format identifier for all internal Xids or newly created Xids.

HEX_DIGITS

protected static final char[] HEX_DIGITS
Efficient mapping from 4 bit value to lower case hexadecimal digit.

XID_PREFIX

public static final String XID_PREFIX
Prefix for textual identifier.

_string

protected String _string
The textual representation of the transaction identifier.

Method Detail

createPrefix

protected static final char[] createPrefix(int formatId)

hashCode

public int hashCode()

newBranch

public abstract Xid newBranch()
Creates a new transaction branch. A transaction branch has the same format and global transaction identifier as this transaction identifier, but a new unique branch qualifier (never empty).

Returns: A new transaction branch

toString

public String toString()
Original code is Copyright (c) 1999-2001, Intalio, Inc. All Rights Reserved. Contributions by MetaBoss team are Copyright (c) 2003-2005, Softaris Pty. Ltd. All Rights Reserved.