public class SignatureKey extends Object implements Comparable<SignatureKey>
Represents a method key for methods within the same class hierarchy.
| Constructor and Description |
|---|
SignatureKey(Method method)
Creates a
SignatureKey from the method. |
SignatureKey(String name,
Class<?>... parameterTypes)
Creates a
SignatureKey from the given name and
parameter types. |
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(SignatureKey other)
Compares two signatures on method name, number of parameters, and finally
the parameter types themselves.
|
boolean |
equals(Object o)
Equality of method signatures is done strictly on method name and parameter types.
|
String |
getName()
Gets the method name.
|
Class<?>[] |
getParameterTypes()
Gets the parameter types to the method.
|
int |
hashCode()
Returns the hash code.
|
static Comparator<Method> |
methodComparator()
Returns a
Comparator that compares two methods
on the basis of their signatures. |
public SignatureKey(Method method)
SignatureKey from the method.method - The method from which to create the signaturepublic static Comparator<Method> methodComparator()
Comparator that compares two methods
on the basis of their signatures.public String getName()
public Class<?>[] getParameterTypes()
public boolean equals(Object o)
public int hashCode()
public int compareTo(SignatureKey other)
compareTo in interface Comparable<SignatureKey>other - The other signatureCopyright © 2014. All rights reserved.