Package org.apache.bcel.classfile

# Class SimpleElementValue

java.lang.Object
org.apache.bcel.classfile.ElementValue
org.apache.bcel.classfile.SimpleElementValue

public class SimpleElementValue extends ElementValue

Since:
  6.0

- ## Field Summary

  ### Fields inherited from class org.apache.bcel.classfile.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

  Constructors
  Constructor
  Description
  `SimpleElementValue(int type, int index, ConstantPool cpool)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `dump(DataOutputStream dos)`
  `int`
  `getIndex()`
  `boolean`
  `getValueBoolean()`
  `byte`
  `getValueByte()`
  `char`
  `getValueChar()`
  `double`
  `getValueDouble()`
  `float`
  `getValueFloat()`
  `int`
  `getValueInt()`
  `long`
  `getValueLong()`
  `short`
  `getValueShort()`
  `String`
  `getValueString()`
  `void`
  `setIndex(int index)`
  `String`
  `stringifyValue()`
  `String`
  `toString()`

  ### Methods inherited from class org.apache.bcel.classfile.ElementValue

  `getElementValueType, readElementValue, readElementValue, toShortString`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### SimpleElementValue

    public SimpleElementValue(int type, int index, ConstantPool cpool)

- ## Method Details

  - ### dump

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

  - ### getIndex

    public int getIndex()
    Returns:
      Value entry index in the cpool

  - ### getValueBoolean

    public boolean getValueBoolean()

  - ### getValueByte

    public byte getValueByte()

  - ### getValueChar

    public char getValueChar()

  - ### getValueDouble

    public double getValueDouble()

  - ### getValueFloat

    public float getValueFloat()

  - ### getValueInt

    public int getValueInt()

  - ### getValueLong

    public long getValueLong()

  - ### getValueShort

    public short getValueShort()

  - ### getValueString

    public String getValueString()

  - ### setIndex

    public void setIndex(int index)

  - ### stringifyValue

    public String stringifyValue()
    Specified by:
      `stringifyValue` in class `ElementValue`

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `ElementValue`