org.apache.bcel.classfile
public final class ConstantString extends Constant implements ConstantObject
See Also: Constant
Constructor Summary | |
---|---|
ConstantString(ConstantString c)
Initialize from another object. | |
ConstantString(int string_index) |
Method Summary | |
---|---|
void | accept(Visitor v)
Called by objects that are traversing the nodes of the tree implicitely
defined by the contents of a Java class. |
void | dump(DataOutputStream file)
Dump constant field reference to file stream in binary format.
|
String | getBytes(ConstantPool cp) |
Object | getConstantValue(ConstantPool cp) |
int | getStringIndex() |
void | setStringIndex(int string_index) |
String | toString() |
Parameters: string_index Index of Constant_Utf8 in constant pool
Parameters: v Visitor object
Parameters: file Output file stream
Throws: IOException
Returns: dereferenced string
Returns: String object
Returns: Index in constant pool of the string (ConstantUtf8).
Parameters: string_index the index into the constant of the string value
Returns: String representation.