java.lang.reflect
Class Method

java.lang.Object
  extended byjava.lang.reflect.Method
All Implemented Interfaces:
Member

public class Method
extends Object
implements Member


Field Summary
 
Fields inherited from interface java.lang.reflect.Member
DECLARED, PUBLIC
 
Constructor Summary
Method(Method method)
           
 
Method Summary
 boolean equals(Object other)
          Returns if this object is considered equal to the other object.
 Class getDeclaringClass()
          Gets the class that declared this member.
 Class[] getExceptionTypes()
           
 int getModifiers()
          Gets the modifiers this member uses.
 String getName()
          Gets the simple name of this member.
 Class[] getParameterTypes()
           
 Class getReturnType()
          Return the type of the Field as a Class object.
 int hashCode()
          Returns a hashCode for the object.
 Object invoke(Object target, Object[] args)
           
 String toString()
          Return a String representation of this object.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass
 

Constructor Detail

Method

public Method(Method method)
Method Detail

getParameterTypes

public Class[] getParameterTypes()

getReturnType

public Class getReturnType()
Return the type of the Field as a Class object.


getName

public String getName()
Description copied from interface: Member
Gets the simple name of this member. This will be a valid Java identifier, with no qualification.

Specified by:
getName in interface Member
Returns:
the name of this member

getModifiers

public int getModifiers()
Description copied from interface: Member
Gets the modifiers this member uses. Use the Modifier class to interpret the values.

Specified by:
getModifiers in interface Member
Returns:
an integer representing the modifiers to this Member
See Also:
Modifier

getDeclaringClass

public Class getDeclaringClass()
Description copied from interface: Member
Gets the class that declared this member. This is not the class where this method was called, or even the class where this Member object came to life, but the class that declares the member this represents.

Specified by:
getDeclaringClass in interface Member
Returns:
the class that declared this member

hashCode

public int hashCode()
Description copied from class: Object
Returns a hashCode for the object. The general contract of hashCode is:
  • An object must return the same hash code for its entire existence.
  • If two objects are considered equal by the equals() method, they should return the same hash code. Not all Objects will do this and you should only use hashCode() from Objects which declare an overrided version of hashCode(). The only Objects which provide consistent and correct hash codes under Ewe are Object, String and Class.

    Overrides:
    hashCode in class Object

  • getExceptionTypes

    public Class[] getExceptionTypes()

    toString

    public String toString()
    Description copied from class: Object
    Return a String representation of this object.

    Overrides:
    toString in class Object
    Returns:
    a String representing this object.

    equals

    public boolean equals(Object other)
    Description copied from class: Object
    Returns if this object is considered equal to the other object.

    Overrides:
    equals in class Object
    Parameters:
    other - Another object to compare to.
    Returns:
    true if this object is considered equal to the other object.

    invoke

    public Object invoke(Object target,
                         Object[] args)
                  throws IllegalAccessException,
                         IllegalArgumentException,
                         InvocationTargetException
    Throws:
    IllegalAccessException
    IllegalArgumentException
    InvocationTargetException