openlist.Symbol Class Reference

List of all members.

Public Member Functions

String toString ()
boolean equals (Object ob)
int compareTo (Object other)

Static Public Member Functions

static Symbol intern (String name)

Package Attributes

String printName


Detailed Description

The Symbol class represents interned Strings. Each is guarnteed to be stored uniquely if the function intern is applied to return the reference to the symbol.

Author:
Robert Keller

Member Function Documentation

int openlist.Symbol.compareTo ( Object  other  ) 

Compare this Symbol to another, based on String comparision of printNames.

Parameters:
other the Object to which this Symbol is compared
Returns:
a negative number if this compares less than the argument, 0 if it compares equal to the argument, and a positive number otherwise

boolean openlist.Symbol.equals ( Object  ob  ) 

Two Symbols are equal iff they are the same Symbol.

Parameters:
ob the Object to which this Symbol is compared for equality
Returns:
true if this Symbol is the same as the argument

static Symbol openlist.Symbol.intern ( String  name  )  [static]

Intern a String as a symbol. If the Symbol named by the string already exists, that symbol is returned. Otherwise a new symbol is created with the name, and that is returned.

Parameters:
name 
Returns:
the Symbol that interns the named String

String openlist.Symbol.toString (  ) 

the printable name of this Symbol

Returns:
the name of this Symbol


Member Data Documentation

String openlist.Symbol.printName [package]

The printable name for this symbol.


The documentation for this class was generated from the following file:

Generated on Thu Oct 29 10:51:32 2009 by  doxygen 1.5.8