Open SiteSearch 4.1.1
Final

ORG.oclc.xml.util
Class Atom

java.lang.Object
  |
  +--ORG.oclc.xml.util.Atom

public class Atom
extends Object

This is a general purpose object to allow efficient sharing of duplicate strings in the system. It does this by creating a global HashTable of all Atoms that have been constructed.


Method Summary
static Atom create(String s)
          Create a Atom object for this string.
 boolean equals(Object that)
          Return whether this Atom is equal to another given Atom.
 int hashCode()
          Return the hash code for the name.
 String toString()
          Return the string represented by the Atom.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Method Detail

create

public static Atom create(String s)
Create a Atom object for this string. Atoms are case sensitive - i.e. it assumes any case folding has already been done.

hashCode

public int hashCode()
Return the hash code for the name.
Returns:
returns the hash code for the name.
Overrides:
hashCode in class Object

toString

public String toString()
Return the string represented by the Atom.
Overrides:
toString in class Object

equals

public boolean equals(Object that)
Return whether this Atom is equal to another given Atom.
Overrides:
equals in class Object

Open SiteSearch 4.1.1
Final