Package org.apache.bcel.classfile
Class AnnotationElementValue
- java.lang.Object
-
- org.apache.bcel.classfile.ElementValue
-
- org.apache.bcel.classfile.AnnotationElementValue
-
public class AnnotationElementValue extends ElementValue
Represents an annotation element value.- Since:
- 6.0
-
-
Field Summary
Fields Modifier and Type Field Description private AnnotationEntryannotationEntry-
Fields inherited from class org.apache.bcel.classfile.ElementValue
ANNOTATION, ARRAY, CLASS, cpool, EMPTY_ARRAY, 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 AnnotationElementValue(int type, AnnotationEntry annotationEntry, ConstantPool cpool)Constructs an AnnotationElementValue.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddump(java.io.DataOutputStream dos)Dumps this element value to a DataOutputStream.AnnotationEntrygetAnnotationEntry()Gets the annotation entry.java.lang.StringstringifyValue()Returns a string representation of the element value.java.lang.StringtoString()Returns a string representation of the element value.-
Methods inherited from class org.apache.bcel.classfile.ElementValue
getConstantPool, getElementValueType, getType, readElementValue, readElementValue, toShortString
-
-
-
-
Field Detail
-
annotationEntry
private final AnnotationEntry annotationEntry
-
-
Constructor Detail
-
AnnotationElementValue
public AnnotationElementValue(int type, AnnotationEntry annotationEntry, ConstantPool cpool)Constructs an AnnotationElementValue.- Parameters:
type- the type.annotationEntry- the annotation entry.cpool- the constant pool.
-
-
Method Detail
-
dump
public void dump(java.io.DataOutputStream dos) throws java.io.IOExceptionDescription copied from class:ElementValueDumps this element value to a DataOutputStream.- Specified by:
dumpin classElementValue- Parameters:
dos- the output stream.- Throws:
java.io.IOException- if an I/O error occurs.
-
getAnnotationEntry
public AnnotationEntry getAnnotationEntry()
Gets the annotation entry.- Returns:
- the annotation entry.
-
stringifyValue
public java.lang.String stringifyValue()
Description copied from class:ElementValueReturns a string representation of the element value.- Specified by:
stringifyValuein classElementValue- Returns:
- a string representation of the element value.
-
toString
public java.lang.String toString()
Description copied from class:ElementValueReturns a string representation of the element value.- Overrides:
toStringin classElementValue- Returns:
- a string representation of the element value.
-
-