org.codehaus.groovy.runtime
Class NewInstanceMetaMethod
java.lang.Object
groovy.lang.MetaMethod
org.codehaus.groovy.runtime.NewInstanceMetaMethod
- All Implemented Interfaces:
- java.lang.Cloneable
public class NewInstanceMetaMethod
- extends MetaMethod
A MetaMethod implementation where the underlying method is really a static
helper method on some class but it appears to be an instance method on a class.
This implementation is used to add new methods to the JDK writing them as normal
static methods with the first parameter being the class on which the method is added.
- Version:
- $Revision: 4550 $
- Author:
- James Strachan
Methods inherited from class groovy.lang.MetaMethod |
checkParameters, clone, compatibleModifiers, equal, getCallClass, getInterfaceClass, getMethodIndex, getName, getReflector, getReturnType, isCacheable, isMethod, isPrivate, isProtected, isPublic, isSame, setCallClass, setInterfaceClass, setMethodIndex, setReflector, toString |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
NewInstanceMetaMethod
public NewInstanceMetaMethod(MetaMethod metaMethod)
NewInstanceMetaMethod
public NewInstanceMetaMethod(java.lang.String name,
java.lang.Class declaringClass,
java.lang.Class[] parameterTypes,
java.lang.Class returnType,
int modifiers)
getDeclaringClass
public java.lang.Class getDeclaringClass()
- Overrides:
getDeclaringClass
in class MetaMethod
isStatic
public boolean isStatic()
- Overrides:
isStatic
in class MetaMethod
getModifiers
public int getModifiers()
- Overrides:
getModifiers
in class MetaMethod
getParameterTypes
public java.lang.Class[] getParameterTypes()
- Overrides:
getParameterTypes
in class MetaMethod
getBytecodeParameterTypes
public java.lang.Class[] getBytecodeParameterTypes()
invoke
public java.lang.Object invoke(java.lang.Object object,
java.lang.Object[] arguments)
- Overrides:
invoke
in class MetaMethod
getOwnerClass
public java.lang.Class getOwnerClass()
Copyright © 2003-2011 The Codehaus. All Rights Reserved.