|
CharConstant.java
|
// FILE. . . . . /home/hak/hlt/src/hlt/osfv3/base/CharConstant.java // EDIT BY . . . Hassan Ait-Kaci // ON MACHINE. . Hak-Laptop // STARTED ON. . Mon Sep 02 16:47:11 2013
This is the class for character constants.
|
package hlt.osf.base; import hlt.osf.exec.Taxonomy; public class CharConstant extends Constant {
| Constructs a new CharConstant with the given value. |
public CharConstant (char value)
{
_sort = Taxonomy.CHAR;
_value = value;
}
| The value if this constant. |
private char _value;
| Return the char value of this CharConstant. |
public char value ()
{
return _value;
}
| Returns true iff the specified object is a CharConstant carrying the same value as this one. |
public boolean equals (Object other)
{
if (!(other instanceof CharConstant))
return false;
return _value == ((CharConstant)other).value();
}
| Returns a String representation of this CharConstant. |
public String toString ()
{
return Character.toString(_value);
}
| Returns a String representation of this StringConstant between single quotes. |
public String toQuotedString ()
{
return "'"+_value+"'";
}
public String displayForm ()
{
return toQuotedString();
}
}
This file was generated on Mon Sep 09 09:17:59 PDT 2019 from file CharConstant.java
by the hlt.language.tools.Hilite Java tool written by Hassan Aït-Kaci