public class HandleMetaClass extends DelegatingMetaClass
delegate| Constructor and Description |
|---|
HandleMetaClass(MetaClass mc) |
HandleMetaClass(MetaClass mc,
Object obj) |
| Modifier and Type | Method and Description |
|---|---|
void |
addMetaBeanProperty(MetaBeanProperty metaBeanProperty)
Adds a new MetaBeanProperty to the MetaClass
|
void |
addMetaMethod(MetaMethod metaMethod)
Adds a new MetaMethod to the MetaClass
|
void |
addNewInstanceMethod(Method method)
adds a new instance method to this MetaClass.
|
void |
addNewStaticMethod(Method method)
adds a new static method to this MetaClass.
|
boolean |
equals(Object obj) |
Object |
getProperty(String property)
Retrieves a property value.
|
void |
initialize()
Complete the initialisation process.
|
Object |
invokeMethod(String name,
Object args)
Invokes the given method.
|
GroovyObject |
replaceDelegate() |
void |
setProperty(String property,
Object newValue)
Sets the given property to the new value.
|
getAdaptee, getAttribute, getAttribute, getClassNode, getMetaClass, getMetaMethod, getMetaMethods, getMetaProperty, getMethods, getProperties, getProperty, getProperty, getStaticMetaMethod, getStaticMetaMethod, getTheClass, hashCode, hasProperty, invokeConstructor, invokeMethod, invokeMethod, invokeMethod, invokeMissingMethod, invokeMissingProperty, invokeStaticMethod, isGroovyObject, isModified, pickMethod, respondsTo, respondsTo, selectConstructorAndTransformArguments, setAdaptee, setAttribute, setAttribute, setMetaClass, setProperty, setProperty, toStringpublic HandleMetaClass(MetaClass mc)
public void initialize()
MetaClassinitialize in interface MetaClassinitialize in class DelegatingMetaClasspublic GroovyObject replaceDelegate()
public Object invokeMethod(String name, Object args)
GroovyObjectinvokeMethod in interface GroovyObjectinvokeMethod in class DelegatingMetaClassname - the name of the method to callargs - the arguments to use for the method callpublic Object getProperty(String property)
GroovyObjectgetProperty in interface GroovyObjectgetProperty in class DelegatingMetaClassproperty - the name of the property of interestpublic void setProperty(String property, Object newValue)
GroovyObjectsetProperty in interface GroovyObjectsetProperty in class DelegatingMetaClassproperty - the name of the property of interestnewValue - the new value for the propertypublic void addNewInstanceMethod(Method method)
MutableMetaClassaddNewInstanceMethod in interface MutableMetaClassaddNewInstanceMethod in class DelegatingMetaClassmethod - the method to be addedpublic void addNewStaticMethod(Method method)
MutableMetaClassaddNewStaticMethod in interface MutableMetaClassaddNewStaticMethod in class DelegatingMetaClassmethod - the method to be addedpublic void addMetaMethod(MetaMethod metaMethod)
MutableMetaClassaddMetaMethod in interface MutableMetaClassaddMetaMethod in class DelegatingMetaClassmetaMethod - The MetaMethod to addpublic void addMetaBeanProperty(MetaBeanProperty metaBeanProperty)
MutableMetaClassaddMetaBeanProperty in interface MutableMetaClassaddMetaBeanProperty in class DelegatingMetaClassmetaBeanProperty - The MetaBeanProperty instancepublic boolean equals(Object obj)
equals in class DelegatingMetaClass