public class EnumMemberValue extends MemberValue
Constructor | Description |
---|---|
EnumMemberValue(int type,
int value,
ConstPool cp) |
Constructs an enum constant value.
|
EnumMemberValue(ConstPool cp) |
Constructs an enum constant value.
|
Modifier and Type | Method | Description |
---|---|---|
void |
accept(MemberValueVisitor visitor) |
Accepts a visitor.
|
String |
getType() |
Obtains the enum type name.
|
String |
getValue() |
Obtains the name of the enum constant value.
|
void |
setType(String typename) |
Changes the enum type name.
|
void |
setValue(String name) |
Changes the name of the enum constant value.
|
String |
toString() |
|
void |
write(AnnotationsWriter writer) |
Writes the value.
|
public EnumMemberValue(int type, int value, ConstPool cp)
type
- the index of a CONSTANT_Utf8_info structure
representing the enum type.value
- the index of a CONSTANT_Utf8_info structure.
representing the enum value.public EnumMemberValue(ConstPool cp)
public String getType()
public void setType(String typename)
typename
- a fully-qualified type name.public String getValue()
public void setValue(String name)
public void write(AnnotationsWriter writer) throws IOException
write
in class MemberValue
IOException
public void accept(MemberValueVisitor visitor)
accept
in class MemberValue
Copyright © 2018 Shigeru Chiba, www.javassist.org. All rights reserved.