public final class Method extends FieldOrMethod
| Modifier and Type | Field and Description |
|---|---|
static Method[] |
EMPTY_ARRAY
Empty array constant.
|
attributes, attributes_count, constant_pool, name_index, signature_indexaccess_flags| Constructor and Description |
|---|
Method()
Empty constructor, all attributes have to be defined via `setXXX' methods.
|
Method(int accessFlags,
int nameIndex,
int signatureIndex,
Attribute[] attributes,
ConstantPool constantPool) |
Method(Method c)
Initialize from another object.
|
| Modifier and Type | Method and Description |
|---|---|
void |
accept(Visitor v)
Called by objects that are traversing the nodes of the tree implicitly defined by the contents of a Java class.
|
Method |
copy(ConstantPool constantPool) |
boolean |
equals(Object obj)
Return value as defined by given BCELComparator strategy.
|
Type[] |
getArgumentTypes() |
Code |
getCode() |
static BCELComparator |
getComparator() |
ExceptionTable |
getExceptionTable() |
LineNumberTable |
getLineNumberTable() |
LocalVariableTable |
getLocalVariableTable() |
ParameterAnnotationEntry[] |
getParameterAnnotationEntries() |
Type |
getReturnType() |
int |
hashCode()
Return value as defined by given BCELComparator strategy.
|
static void |
setComparator(BCELComparator comparator) |
String |
toString()
Return string representation close to declaration format, `public static void main(String[] args) throws
IOException', e.g.
|
copy_, dump, getAnnotationEntries, getAttributes, getConstantPool, getGenericSignature, getName, getNameIndex, getSignature, getSignatureIndex, setAttributes, setConstantPool, setNameIndex, setSignatureIndexgetAccessFlags, getModifiers, isAbstract, isAbstract, isAnnotation, isAnnotation, isEnum, isEnum, isFinal, isFinal, isInterface, isInterface, isNative, isNative, isPrivate, isPrivate, isProtected, isProtected, isPublic, isPublic, isStatic, isStatic, isStrictfp, isStrictfp, isSynchronized, isSynchronized, isSynthetic, isSynthetic, isTransient, isTransient, isVarArgs, isVarArgs, isVolatile, isVolatile, setAccessFlags, setModifierspublic static final Method[] EMPTY_ARRAY
public Method()
public Method(int accessFlags, int nameIndex, int signatureIndex, Attribute[] attributes, ConstantPool constantPool)
accessFlags - Access rights of methodnameIndex - Points to field name in constant poolsignatureIndex - Points to encoded signatureattributes - Collection of attributesconstantPool - Array of constantspublic static BCELComparator getComparator()
public static void setComparator(BCELComparator comparator)
comparator - Comparison strategy objectpublic void accept(Visitor v)
v - Visitor objectpublic Method copy(ConstantPool constantPool)
public boolean equals(Object obj)
equals in class ObjectObject.equals(Object)public Type[] getArgumentTypes()
public ExceptionTable getExceptionTable()
public LineNumberTable getLineNumberTable()
public LocalVariableTable getLocalVariableTable()
public ParameterAnnotationEntry[] getParameterAnnotationEntries()
public Type getReturnType()
public int hashCode()
hashCode in class ObjectObject.hashCode()Copyright © 2004–2022 The Apache Software Foundation. All rights reserved.