Building Parsers with Java

sjm.examples.query
Class ChipSpeller

java.lang.Object
  |
  +--sjm.examples.query.ChipSpeller

public class ChipSpeller
extends java.lang.Object
implements Speller

This class maintains dictionaries of the proper spelling of class and variable names in the chip object model.


Field Summary
protected  java.util.Dictionary classNames
           
protected  java.util.Dictionary variableNames
           
 
Constructor Summary
ChipSpeller()
          Initialize the ChipSpeller.
 
Method Summary
protected  void addClassName(java.lang.String s)
           
protected  void addVariableName(java.lang.String s)
           
 java.lang.String getClassName(java.lang.String s)
          Return the properly capitalized spelling of a class name, given any capitalization of the name.
 java.lang.String getVariableName(java.lang.String s)
          Return the properly capitalized spelling of a variable name, given any capitalization of the name.
protected  void loadClassNames()
           
protected  void loadVariableNames()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

classNames

protected java.util.Dictionary classNames

variableNames

protected java.util.Dictionary variableNames
Constructor Detail

ChipSpeller

public ChipSpeller()
Initialize the ChipSpeller.
Method Detail

addClassName

protected void addClassName(java.lang.String s)

addVariableName

protected void addVariableName(java.lang.String s)

getClassName

public java.lang.String getClassName(java.lang.String s)
Return the properly capitalized spelling of a class name, given any capitalization of the name.
Specified by:
getClassName in interface Speller
Returns:
the properly capitalized spelling of a class name, given any capitalization of the name.

getVariableName

public java.lang.String getVariableName(java.lang.String s)
Return the properly capitalized spelling of a variable name, given any capitalization of the name.
Specified by:
getVariableName in interface Speller
Returns:
the properly capitalized spelling of a variable name, given any capitalization of the name.

loadClassNames

protected void loadClassNames()

loadVariableNames

protected void loadVariableNames()

by Steve Metsker