Package: org.codehaus.groovy.grails.commons.metaclass

## [Java] Class AbstractDynamicMethods

- org.codehaus.groovy.grails.commons.metaclass.AbstractDynamicMethods

- All Implemented Interfaces and Traits:
    DynamicMethods

      public abstract class AbstractDynamicMethods
      extends java.lang.Object

  Provides the base implementation responsible for performing dynamic method invocation such as the dynamic finders in GORM.

  Authors:
    Steven Devijver
    Graeme Rocher
  Since:
    0.1

- - ### Field Summary

    Fields
    Modifiers | Name | Description
    --- | --- | ---
    `protected java.lang.Class<?>` | `clazz` |
    `protected java.util.Collection<DynamicConstructor>` | `dynamicConstructors` |
    `protected java.util.Collection<DynamicMethodInvocation>` | `dynamicMethodInvocations` |
    `protected java.util.Map<java.lang.String, DynamicProperty>` | `dynamicProperties` |
    `protected java.util.Collection<StaticMethodInvocation>` | `staticMethodInvocations` |

  - ### Constructor Summary

    Constructors
    Constructor and description
    `AbstractDynamicMethods (java.lang.Class<?> theClass)` Creates and registers a DelegatingMetaClass instance in the registry that delegates to this class.
    `AbstractDynamicMethods (java.lang.Class<?> theClass, boolean inRegistry)` Creates and optionally registers a DelegatingMetaClass in the MetaClasRegistry that delegates to this class.
    `AbstractDynamicMethods ()` A non-registering constructor that simple creates an instance

  - ### Methods Summary

    Methods
    Type | Name and description
    --- | ---
    `void` | `addDynamicConstructor(DynamicConstructor constructor)`
    `void` | `addDynamicMethodInvocation(DynamicMethodInvocation methodInvocation)`
    `void` | `addDynamicProperty(DynamicProperty property)`
    `void` | `addStaticMethodInvocation(StaticMethodInvocation methodInvocation)`
    `DynamicMethodInvocation` | `getDynamicMethod(java.lang.String methodSignature)`
    `DynamicProperty` | `getDynamicProperty(java.lang.String propertyName)`
    `java.lang.Object` | `getProperty(java.lang.Object object, java.lang.String propertyName, InvocationCallback callback)`
    `java.lang.Object` | `invokeConstructor(java.lang.Object[] arguments, InvocationCallback callBack)`
    `java.lang.Object` | `invokeMethod(java.lang.Object object, java.lang.String methodName, java.lang.Object[] arguments, InvocationCallback callback)`
    `java.lang.Object` | `invokeStaticMethod(java.lang.Object object, java.lang.String methodName, java.lang.Object[] arguments, InvocationCallback callBack)`
    `void` | `setProperty(java.lang.Object object, java.lang.String propertyName, java.lang.Object newValue, InvocationCallback callback)`

  - ### Inherited Methods Summary

    Inherited Methods
    Methods inherited from class | Name
    --- | ---
    `class java.lang.Object` | `java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll()`

- - ### Field Detail

    - #### protected java.lang.Class<?> clazz

    - #### protected java.util.Collection<DynamicConstructor> dynamicConstructors

    - #### protected java.util.Collection<DynamicMethodInvocation> dynamicMethodInvocations

    - #### protected java.util.Map<java.lang.String, DynamicProperty> dynamicProperties

    - #### protected java.util.Collection<StaticMethodInvocation> staticMethodInvocations

  - ### Constructor Detail

    - #### public AbstractDynamicMethods(java.lang.Class<?> theClass)

      Creates and registers a DelegatingMetaClass instance in the registry that delegates to this class.

      Parameters:
        theClass

    - #### public AbstractDynamicMethods(java.lang.Class<?> theClass, boolean inRegistry)

      Creates and optionally registers a DelegatingMetaClass in the MetaClasRegistry that delegates to this class.

      Parameters:
        theClass
        inRegistry

    - #### public AbstractDynamicMethods()

      A non-registering constructor that simple creates an instance

  - ### Method Detail

    - #### public void addDynamicConstructor(DynamicConstructor constructor)

    - #### public void addDynamicMethodInvocation(DynamicMethodInvocation methodInvocation)

    - #### public void addDynamicProperty(DynamicProperty property)

    - #### public void addStaticMethodInvocation(StaticMethodInvocation methodInvocation)

    - #### public DynamicMethodInvocation getDynamicMethod(java.lang.String methodSignature)

    - #### public DynamicProperty getDynamicProperty(java.lang.String propertyName)

    - #### public java.lang.Object getProperty(java.lang.Object object, java.lang.String propertyName, InvocationCallback callback)

    - #### public java.lang.Object invokeConstructor(java.lang.Object[] arguments, InvocationCallback callBack)

    - #### public java.lang.Object invokeMethod(java.lang.Object object, java.lang.String methodName, java.lang.Object[] arguments, InvocationCallback callback)

    - #### public java.lang.Object invokeStaticMethod(java.lang.Object object, java.lang.String methodName, java.lang.Object[] arguments, InvocationCallback callBack)

    - #### public void setProperty(java.lang.Object object, java.lang.String propertyName, java.lang.Object newValue, InvocationCallback callback)