Module de.carne.mcd.jvmdecoder
Class NameAndTypeConstant
- java.lang.Object
-
- de.carne.mcd.jvmdecoder.classfile.ClassInfoElement
-
- de.carne.mcd.jvmdecoder.classfile.constant.Constant
-
- de.carne.mcd.jvmdecoder.classfile.constant.NameAndTypeConstant
-
-
Field Summary
Fields Modifier and Type Field Description static intTAGNameAndType constant tag.-
Fields inherited from class de.carne.mcd.jvmdecoder.classfile.ClassInfoElement
classInfo
-
-
Constructor Summary
Constructors Constructor Description NameAndTypeConstant(ClassInfo classInfo, int nameIndex, int descriptorIndex)Constructs a new NameAndTypeConstant instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetDescriptorValue()Gets this constant's descriptor value.java.lang.StringgetNameValue()Gets this constant's name value.voidprint(ClassPrinter out, ClassContext context)Prints this instance.java.lang.StringtoString()-
Methods inherited from class de.carne.mcd.jvmdecoder.classfile.constant.Constant
resolveSymbol
-
-
-
-
Field Detail
-
TAG
public static final int TAG
NameAndType constant tag.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
NameAndTypeConstant
public NameAndTypeConstant(ClassInfo classInfo, int nameIndex, int descriptorIndex)
Constructs a new NameAndTypeConstant instance.- Parameters:
classInfo- the ClassInfo instance this constant is part of.nameIndex- the name index.descriptorIndex- the type descriptor index.
-
-
Method Detail
-
getNameValue
public java.lang.String getNameValue() throws java.io.IOExceptionGets this constant's name value.- Returns:
- this constant's name value.
- Throws:
java.io.IOException- if the value cannot be resolved.
-
getDescriptorValue
public java.lang.String getDescriptorValue() throws java.io.IOExceptionGets this constant's descriptor value.- Returns:
- this constant's descriptor value.
- Throws:
java.io.IOException- if the value cannot be resolved.
-
print
public void print(ClassPrinter out, ClassContext context) throws java.io.IOException
Description copied from interface:PrintablePrints this instance.- Parameters:
out- the ClassPrinter instance to print to.context- the context of this print invocation.- Throws:
java.io.IOException- if an I/O error occurs.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-