org.apache.xml.serializer
Class CharInfo.CharKey

java.lang.Object
  extended by org.apache.xml.serializer.CharInfo.CharKey
Enclosing class:
CharInfo

private static class CharInfo.CharKey
extends java.lang.Object

Simple class for fast lookup of char values, when used with hashtables. You can set the char, then use it as a key.


Field Summary
private  char m_char
          String value
 
Constructor Summary
CharInfo.CharKey()
          Default constructor for a CharKey.
CharInfo.CharKey(char key)
          Constructor CharKey
 
Method Summary
 boolean equals(java.lang.Object obj)
          Override of equals() for this object
 int hashCode()
          Get the hash value of the character.
 void setChar(char c)
          Get the hash value of the character.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_char

private char m_char
String value

Constructor Detail

CharInfo.CharKey

public CharInfo.CharKey(char key)
Constructor CharKey

Parameters:
key - char value of this object.

CharInfo.CharKey

public CharInfo.CharKey()
Default constructor for a CharKey.

Parameters:
key - char value of this object.
Method Detail

setChar

public final void setChar(char c)
Get the hash value of the character.


hashCode

public final int hashCode()
Get the hash value of the character.

Overrides:
hashCode in class java.lang.Object
Returns:
hash value of the character.

equals

public final boolean equals(java.lang.Object obj)
Override of equals() for this object

Overrides:
equals in class java.lang.Object
Parameters:
obj - to compare to
Returns:
True if this object equals this string value