org.apache.commons.beanutils
Class MethodUtils.MethodDescriptor

java.lang.Object
  |
  +--org.apache.commons.beanutils.MethodUtils.MethodDescriptor
Enclosing class:
MethodUtils

private static class MethodUtils.MethodDescriptor
extends java.lang.Object

Represents the key to looking up a Method by reflection.


Field Summary
private  java.lang.Class cls
           
private  boolean exact
           
private  int hashCode
           
private  java.lang.String methodName
           
private  java.lang.Class[] paramTypes
           
 
Constructor Summary
MethodUtils.MethodDescriptor(java.lang.Class cls, java.lang.String methodName, java.lang.Class[] paramTypes, boolean exact)
          The sole constructor.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Checks for equality.
 int hashCode()
          Returns the string length of method name.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

cls

private java.lang.Class cls

methodName

private java.lang.String methodName

paramTypes

private java.lang.Class[] paramTypes

exact

private boolean exact

hashCode

private int hashCode
Constructor Detail

MethodUtils.MethodDescriptor

public MethodUtils.MethodDescriptor(java.lang.Class cls,
                                    java.lang.String methodName,
                                    java.lang.Class[] paramTypes,
                                    boolean exact)
The sole constructor.

Parameters:
cls - the class to reflect, must not be null
methodName - the method name to obtain
paramTypes - the array of classes representing the paramater types
exact - whether the match has to be exact.
Method Detail

equals

public boolean equals(java.lang.Object obj)
Checks for equality.

Overrides:
equals in class java.lang.Object
Parameters:
obj - object to be tested for equality
Returns:
true, if the object describes the same Method.

hashCode

public int hashCode()
Returns the string length of method name. I.e. if the hashcodes are different, the objects are different. If the hashcodes are the same, need to use the equals method to determine equality.

Overrides:
hashCode in class java.lang.Object
Returns:
the string length of method name.


Copyright (c) 2001-2004 - Apache Software Foundation