|
||||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |
Const interface
Const (constant) class interface. A constant in source program is recorded as a Const instance by using its character string representation as its name. There are access methods to get the value of constants and to record a constant giving its value. Constants are usually represented by symbol table instance in order to represent attributes attached to them. Subclasses of Const is not so fine as type, foe example, int, short, long, unsigned int, unsigned short, unsigned long all belongs to IntConst. To see the type of Const object, use getSymType() of SymInterface.
フィールドの概要 |
インタフェース coins.sym.Sym から継承したフィールド |
KIND_NAME, VISIBILITY |
メソッドの概要 | |
char |
charValue()
charValue Get the value of this constant. |
double |
doubleValue()
doubleValue Get double value of this constant. |
java.lang.Object |
evaluateAsObject()
Get the value of this constant symbol. |
float |
floatValue()
floatValue Get floating value of this constant. |
Const |
getConstSym()
getConstSym If boolean true then return symRoot.intConst1 else if boolean false then return symRoot.intConst0 else if enumeration constant then return corresponding IntConst else return this. |
int |
intValue()
intValue Get the value of this constant. |
long |
longValue()
longValue Get the value of this constant. |
short |
shortValue()
shortValue Get the value of this constant. |
インタフェース coins.sym.Sym0 から継承したメソッド |
charConst, definedType, defineElem, defineLabel, defineParam, defineSubp, defineVar, enumType, floatConst, getDefinedFile, getDefinedIn, getFlag, getName, getNextSym, getRecordedIn, getSymKind, getSymType, getUniqueName, intConst, isGlobal, namedConst, pointerType, setFlag, stringConst, structType, subpType, unionType, vectorType, vectorTypeUnfixed |
メソッドの詳細 |
public int intValue()
public short shortValue()
Get the value of this constant. If type conversion is required, the returned value is the result of conversion. "this" should be a constant of type integer, short integer, long integer, or character of either signed or unsigned.
public long longValue()
Get the value of this constant. If type conversion is required, the returned value is the result of conversion. "this" should be a constant of type integer, short integer, long integer, or character of either signed or unsigned.
public char charValue()
Get the value of this constant. If type conversion is required, the returned value is the result of conversion. "this" should be a constant of type integer, short integer, long integer, or character of either signed or unsigned.
public float floatValue()
Get floating value of this constant. If type conversion is required, the returned value is the result of conversion. "this" should be a constant of type float, or double.
public double doubleValue()
Get double value of this constant. If type conversion is required, the returned value is the result of conversion. "this" should be a constant of type float, or double.
public Const getConstSym()
If boolean true then return symRoot.intConst1 else if boolean false then return symRoot.intConst0 else if enumeration constant then return corresponding IntConst else return this.
public java.lang.Object evaluateAsObject()
Get the value of this constant symbol. This method is overrided as follows: class returned value IntConst Long FloatConst Double StringConst String Var Initail value (ExpListExp, etc.) if qualified by const, else null.
|
||||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |