org.aspectj.apache.bcel.classfile.annotation
Class SimpleElementValue

java.lang.Object
  extended by org.aspectj.apache.bcel.classfile.annotation.ElementValue
      extended by org.aspectj.apache.bcel.classfile.annotation.SimpleElementValue

public class SimpleElementValue
extends ElementValue


Field Summary
 
Fields inherited from class org.aspectj.apache.bcel.classfile.annotation.ElementValue
ANNOTATION, ARRAY, CLASS, cpool, ENUM_CONSTANT, PRIMITIVE_BOOLEAN, PRIMITIVE_BYTE, PRIMITIVE_CHAR, PRIMITIVE_DOUBLE, PRIMITIVE_FLOAT, PRIMITIVE_INT, PRIMITIVE_LONG, PRIMITIVE_SHORT, STRING, type
 
Constructor Summary
  SimpleElementValue(int type, ConstantPool cpGen, boolean value)
           
  SimpleElementValue(int type, ConstantPool cpGen, byte value)
           
  SimpleElementValue(int type, ConstantPool cpGen, char value)
           
  SimpleElementValue(int type, ConstantPool cpGen, double value)
           
  SimpleElementValue(int type, ConstantPool cpGen, float value)
           
  SimpleElementValue(int type, ConstantPool cpGen, int value)
           
  SimpleElementValue(int type, ConstantPool cpGen, long value)
           
  SimpleElementValue(int type, ConstantPool cpGen, short value)
           
  SimpleElementValue(int type, ConstantPool cpGen, java.lang.String value)
           
protected SimpleElementValue(int type, int idx, ConstantPool cpGen)
          Protected ctor used for deserialization, doesn't *put* an entry in the constant pool, assumes the one at the supplied index is correct.
  SimpleElementValue(SimpleElementValue value, ConstantPool cpool, boolean copyPoolEntries)
          The boolean controls whether we copy info from the 'old' constant pool to the 'new'.
 
Method Summary
 void dump(java.io.DataOutputStream dos)
           
 int getIndex()
           
 boolean getValueBoolean()
           
 byte getValueByte()
           
 char getValueChar()
           
 double getValueDouble()
           
 float getValueFloat()
           
 int getValueInt()
           
 long getValueLong()
           
 short getValueShort()
           
 java.lang.String getValueString()
           
 java.lang.String stringifyValue()
           
 java.lang.String toString()
           
 
Methods inherited from class org.aspectj.apache.bcel.classfile.annotation.ElementValue
copy, getConstantPool, getElementValueType, readElementValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SimpleElementValue

protected SimpleElementValue(int type,
                             int idx,
                             ConstantPool cpGen)
Protected ctor used for deserialization, doesn't *put* an entry in the constant pool, assumes the one at the supplied index is correct.


SimpleElementValue

public SimpleElementValue(int type,
                          ConstantPool cpGen,
                          int value)

SimpleElementValue

public SimpleElementValue(int type,
                          ConstantPool cpGen,
                          long value)

SimpleElementValue

public SimpleElementValue(int type,
                          ConstantPool cpGen,
                          double value)

SimpleElementValue

public SimpleElementValue(int type,
                          ConstantPool cpGen,
                          float value)

SimpleElementValue

public SimpleElementValue(int type,
                          ConstantPool cpGen,
                          short value)

SimpleElementValue

public SimpleElementValue(int type,
                          ConstantPool cpGen,
                          byte value)

SimpleElementValue

public SimpleElementValue(int type,
                          ConstantPool cpGen,
                          char value)

SimpleElementValue

public SimpleElementValue(int type,
                          ConstantPool cpGen,
                          boolean value)

SimpleElementValue

public SimpleElementValue(int type,
                          ConstantPool cpGen,
                          java.lang.String value)

SimpleElementValue

public SimpleElementValue(SimpleElementValue value,
                          ConstantPool cpool,
                          boolean copyPoolEntries)
The boolean controls whether we copy info from the 'old' constant pool to the 'new'. You need to use this ctor if the annotation is being copied from one file to another.

Method Detail

getValueByte

public byte getValueByte()

getValueChar

public char getValueChar()

getValueLong

public long getValueLong()

getValueFloat

public float getValueFloat()

getValueDouble

public double getValueDouble()

getValueBoolean

public boolean getValueBoolean()

getValueShort

public short getValueShort()

getIndex

public int getIndex()

getValueString

public java.lang.String getValueString()

getValueInt

public int getValueInt()

stringifyValue

public java.lang.String stringifyValue()
Specified by:
stringifyValue in class ElementValue

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

dump

public void dump(java.io.DataOutputStream dos)
          throws java.io.IOException
Specified by:
dump in class ElementValue
Throws:
java.io.IOException