Package org.jboss.ejb.client
Class SessionID
java.lang.Object
org.jboss.ejb.client.SessionID
- All Implemented Interfaces:
Serializable,Comparable<SessionID>
- Direct Known Subclasses:
BasicSessionID,UnknownSessionID,UUIDSessionID
A session ID for a stateful Enterprise Beans. Session IDs can be stored in multiple formats with different
characteristics.
- Author:
- David M. Lloyd
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classSerialized representation of a session ID.. -
Method Summary
Modifier and TypeMethodDescriptionintstatic SessionIDcreateSessionID(byte[] encoded) Create a session ID object for the given encoded representation.final booleanDetermine whether this object is equal to another.byte[]Get a copy of the encoded form of this session ID.protected byte[]Get the encoded form of this session ID.final inthashCode()toString()protected final ObjectSubstitute this session ID with a serialized representation.
-
Method Details
-
getEncodedForm
public byte[] getEncodedForm()Get a copy of the encoded form of this session ID.- Returns:
- the copy of the encoded form
-
getEncodedFormRaw
protected byte[] getEncodedFormRaw()Get the encoded form of this session ID. Note that callers must take care to avoid modifying the encoded form.- Returns:
- the encoded form
-
equals
Determine whether this object is equal to another. Session IDs are equal if their encoded form is equal and the class is equal. -
hashCode
public final int hashCode() -
compareTo
- Specified by:
compareToin interfaceComparable<SessionID>
-
createSessionID
Create a session ID object for the given encoded representation.- Parameters:
encoded- the encoded representation- Returns:
- the session ID object
-
writeReplace
Substitute this session ID with a serialized representation.- Returns:
- the serialized representation
-
toString
-