public class EnclosingMethodAttribute extends AttributeInfo
EnclosingMethod_attribute
.Modifier and Type | Field and Description |
---|---|
static String |
tag
The name of this attribute
"EnclosingMethod" . |
constPool
Constructor and Description |
---|
EnclosingMethodAttribute(ConstPool cp,
String className)
Constructs an EnclosingMethod attribute.
|
EnclosingMethodAttribute(ConstPool cp,
String className,
String methodName,
String methodDesc)
Constructs an EnclosingMethod attribute.
|
Modifier and Type | Method and Description |
---|---|
int |
classIndex()
Returns the value of
class_index . |
String |
className()
Returns the name of the class specified by
class_index . |
AttributeInfo |
copy(ConstPool newCp,
Map classnames)
Makes a copy.
|
String |
methodDescriptor()
Returns the method descriptor specified by
method_index . |
int |
methodIndex()
Returns the value of
method_index . |
String |
methodName()
Returns the method name specified by
method_index . |
get, getConstPool, getName, length, set
public static final String tag
"EnclosingMethod"
.public EnclosingMethodAttribute(ConstPool cp, String className, String methodName, String methodDesc)
cp
- a constant pool table.className
- the name of the innermost enclosing class.methodName
- the name of the enclosing method.methodDesc
- the descriptor of the enclosing method.public int classIndex()
class_index
.public int methodIndex()
method_index
.public String className()
class_index
.public String methodName()
method_index
.public String methodDescriptor()
method_index
.public AttributeInfo copy(ConstPool newCp, Map classnames)
Map
object.copy
in class AttributeInfo
newCp
- the constant pool table used by the new copy.classnames
- pairs of replaced and substituted
class names.Copyright © 2019. All rights reserved.