org.apache.commons.beanutils

Class MethodUtils.MethodDescriptor

private static class MethodUtils.MethodDescriptor extends Object

Represents the key to looking up a Method by reflection.
Field Summary
Classcls
booleanexact
inthashCode
StringmethodName
Class[]paramTypes
Constructor Summary
MethodDescriptor(Class cls, String methodName, Class[] paramTypes, boolean exact)
The sole constructor.
Method Summary
booleanequals(Object obj)
Checks for equality.
inthashCode()
Returns the string length of method name.

Field Detail

cls

private Class cls

exact

private boolean exact

hashCode

private int hashCode

methodName

private String methodName

paramTypes

private Class[] paramTypes

Constructor Detail

MethodDescriptor

public MethodDescriptor(Class cls, String methodName, 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(Object obj)
Checks for equality.

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.

Returns: the string length of method name.

Copyright (c) 2001-2004 - Apache Software Foundation