| Modifier and Type | Field and Description |
|---|---|
| private final Map | methodByNameMap
Keep track of all methods with the same name. |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public synchronized void | |
| public Method | |
| pack-priv Method | |
| public synchronized List | |
| public synchronized String[] |
| methodByNameMap | back to summary |
|---|---|
| private final Map<String, List<Method>> methodByNameMap Keep track of all methods with the same name. | |
| MethodMap | back to summary |
|---|---|
| pack-priv MethodMap() | |
| add | back to summary |
|---|---|
| public synchronized void add(Method method) Add a method to a list of methods by name. For a particular class we are keeping track of all the methods with the same name.
| |
| find | back to summary |
|---|---|
| public Method find(String methodName, Object[] args) throws AmbiguousException Find a method. Attempts to find the most specific applicable method using the algorithm described in the JLS section 15.12.2 (with the exception that it can't distinguish a primitive type argument from an object type argument, since in reflection primitive type arguments are represented by their object counterparts, so for an argument of type (say) java.lang.Integer, it will not be able to decide between a method that takes int and a method that takes java.lang.Integer as a parameter. This turns out to be a relatively rare case where this is needed - however, functionality like this is needed.
| |
| find | back to summary |
|---|---|
| pack-priv Method find(MethodKey methodKey) throws AmbiguousException Finds a method by key.
| |
| get | back to summary |
|---|---|
| public synchronized List Return a list of methods with the same name. | |
| names | back to summary |
|---|---|
| public synchronized String[] names() Returns the array of method names accessible in this class.
| |