public class MethodDescriptor
extends java.lang.Object
MethodSignature
. A descriptor consists of
parameter types and return type of a method, e.g. "()V" for a void method with no parameters, or
"(II)B" for a method that takes two integers and returns a boolean. Read more about this topic in
ยง4.3.3 of
the JVM specification.Modifier and Type | Field and Description |
---|---|
java.util.List<java.lang.String> |
argumentTypes
Deprecated.
|
java.lang.String |
returnType
Deprecated.
|
Constructor and Description |
---|
MethodDescriptor(java.lang.String descriptor) |
MethodDescriptor(java.lang.String returnType,
java.util.List<java.lang.String> argumentTypes) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o) |
java.util.List<java.lang.String> |
getArgumentTypes() |
java.lang.String |
getPrettyArgumentTypes()
Get the human readable representation of the argument types.
|
java.lang.String |
getPrettyReturnType()
Get the human readable representation of the return type.
|
java.lang.String |
getReturnType() |
int |
hashCode() |
boolean |
isIncomplete()
Check if this descriptor is missing information.
|
static boolean |
matchesIgnoreNull(MethodDescriptor descriptor,
MethodDescriptor wildcard)
Analogous to
MethodSignature.matchesIgnoreNull(MethodSignature, MethodSignature) . |
static boolean |
matchesIgnoreNullAndDollar(MethodDescriptor descriptor,
MethodDescriptor wildcard)
Analogous to
MethodSignature.matchesIgnoreNullAndDollar(MethodSignature,
MethodSignature) . |
java.lang.String |
toString() |
@Deprecated public final java.lang.String returnType
@Deprecated public final java.util.List<java.lang.String> argumentTypes
public MethodDescriptor(java.lang.String descriptor)
public MethodDescriptor(java.lang.String returnType, java.util.List<java.lang.String> argumentTypes)
public boolean isIncomplete()
public java.lang.String getReturnType()
public java.util.List<java.lang.String> getArgumentTypes()
public static boolean matchesIgnoreNull(MethodDescriptor descriptor, MethodDescriptor wildcard)
MethodSignature.matchesIgnoreNull(MethodSignature, MethodSignature)
.descriptor
- The MethodDescriptor
to be comparedwildcard
- The MethodDescriptor
pattern to be matched againstpublic static boolean matchesIgnoreNullAndDollar(MethodDescriptor descriptor, MethodDescriptor wildcard)
MethodSignature.matchesIgnoreNullAndDollar(MethodSignature,
MethodSignature)
.descriptor
- The MethodDescriptor
to be comparedwildcard
- The MethodDescriptor
pattern to be matched againstpublic java.lang.String getPrettyReturnType()
returnType
public java.lang.String getPrettyArgumentTypes()
argumentTypes
public java.lang.String toString()
toString
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object