Class MethodMap

  • All Implemented Interfaces:
    Serializable, Cloneable, Map

    public final class MethodMap
    extends HashMap
    This is an optimized map for resolving java.lang.reflect.Method objects. Doing a method lookup, even on an unsynchronized Map, can be an expensive operation, in many cases taking multiple microseconds. In most situations this overhead is negligible, but it can be noticeable when performed in the common path of a local ejb invocation, where our goal is to be as fast as a raw java method call. A MethodMap must be created with an existing Map and is immutable after construction(except for clear()). It does not support the optional Map operations put, putAll, and remove. NOTE that these operations could be implemented but are not necessary at this point since the main use is for the container's method info, which is invariant after initialization. As this is a map for Method objects, null keys are not supported. This map is unsynchronized.
    See Also:
    Serialized Form