opencard.opt.applet
Class ID

java.lang.Object
  |
  +--opencard.opt.applet.ID
Direct Known Subclasses:
AppletID

public class ID
extends java.lang.Object

ID - A wrapper class for unsigned byte arrays.

Since:
OCF1.2
See Also:
HexString

Constructor Summary
ID(byte[] array)
          Constructs the AppletID from a byte array.
ID(java.lang.String hexString)
          Construct the ID from a hexadecimal string.
 
Method Summary
 boolean equals(java.lang.Object object)
          Checks whether this ID equals another object.
 byte[] getBytes()
          Returns the ID as a byte array.
 int hashCode()
          Returns a hash code for the ID.
 java.lang.String toString()
          Returns the ID as a string.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ID

public ID(byte[] array)
Constructs the AppletID from a byte array.
Parameters:
bytes - Byte array for initialization of the ID.

ID

public ID(java.lang.String hexString)
Construct the ID from a hexadecimal string.
Parameters:
hexString - Hexadecimal string for initialization of the ID.
Method Detail

equals

public boolean equals(java.lang.Object object)
Checks whether this ID equals another object.
Parameters:
object - The object to be compared with this ID.
Overrides:
equals in class java.lang.Object

getBytes

public byte[] getBytes()
Returns the ID as a byte array.
Returns:
The ID as a byte array.

hashCode

public int hashCode()
Returns a hash code for the ID.
Overrides:
hashCode in class java.lang.Object

toString

public java.lang.String toString()
Returns the ID as a string.
Returns:
The ID as a string.
Overrides:
toString in class java.lang.Object