public class SessionKey
extends java.lang.Object
Constructor and Description |
---|
SessionKey(byte[] key)
Create a new key using the input byte array.
|
SessionKey(SessionKey key)
Create a copy of the SessionKey
key . |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj)
2 ByteArray objects are equal if the contents of their
byte[] holds the same values.
|
int |
hashCode() |
java.lang.String |
toString() |
public SessionKey(byte[] key)
key
- byte array of session key valuejava.lang.NullPointerException
- if key
is null
.public SessionKey(SessionKey key)
key
.
Note that the 2 SessionKeys share the byte array, but
since this class is immutable, nothing bad is gonna happen. :)public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object