|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.mmm.util.reflect.api.Signature
public class Signature
This class represents a "method signature"
. It is a container for a Class
array
and can be used as hash-key
.
Field Summary | |
---|---|
private int |
hash
bleeding edge performance hack |
private Class<?>[] |
signature
the wrapped signature |
static Signature |
VOID
the void signature for a non-arg method |
Constructor Summary | |
---|---|
Signature(Class<?>... theSignature)
The constructor. |
|
Signature(Method method)
The constructor. |
|
Signature(Object... arguments)
The constructor. |
Method Summary | |
---|---|
boolean |
equals(Object other)
|
Class<?> |
getType(int position)
This method gets the type of this signature at the given
position. |
int |
getTypeCount()
This method gets the number of types in this signature. |
int |
hashCode()
|
boolean |
isApplicable(Signature s)
This method determines if the given signature is applicable for this signature. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final Signature VOID
private final Class<?>[] signature
private final int hash
Constructor Detail |
---|
public Signature(Class<?>... theSignature)
theSignature
- is the signature to wrap.public Signature(Method method)
method
- is the method whose signature should be wrapped.public Signature(Object... arguments)
arguments
- is a specific argument list to create a signature from.Method Detail |
---|
public boolean isApplicable(Signature s)
s
.contain
null
.
s
- is the signature to test.
true
if the given signature is applicable for this
signature, false
otherwise.public int getTypeCount()
types
in this signature.
public Class<?> getType(int position)
type
of this signature at the given
position.
position
- is the index of the requested type. This value must be in
the range from 0
to
getTypeCount()
- 1
.
type
at the given index.public int hashCode()
hashCode
in class Object
public boolean equals(Object other)
equals
in class Object
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |