|
Groovy Documentation | |||||||
FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object groovy.lang.MetaClassImpl groovy.lang.ProxyMetaClass groovy.mock.interceptor.MockProxyMetaClass
public class MockProxyMetaClass extends ProxyMetaClass
The ProxyMetaClass for the MockInterceptor. Instance and class methods are intercepted, but constructors are not to allow mocking of aggregated objects.
Field Summary | |
---|---|
boolean |
interceptConstruction
|
Method Summary | |
---|---|
java.lang.Object
|
MockProxyMetaClass(MetaClassRegistry registry, java.lang.Class theClass, MetaClass adaptee)
@param adaptee the MetaClass to decorate with interceptability |
java.lang.Object
|
MockProxyMetaClass(MetaClassRegistry registry, java.lang.Class theClass, MetaClass adaptee, boolean interceptConstruction)
@param adaptee the MetaClass to decorate with interceptability |
java.lang.Object
|
getProperty(java.lang.Class aClass, java.lang.Object object, java.lang.String property, boolean b, boolean b1)
|
java.lang.Object
|
invokeConstructor(java.lang.Object[] arguments)
Unlike general impl in superclass, ctors are not intercepted but relayed unless interceptConstruction is set. |
java.lang.Object
|
invokeMethod(java.lang.Object object, java.lang.String methodName, java.lang.Object[] arguments)
|
java.lang.Object
|
invokeStaticMethod(java.lang.Object object, java.lang.String methodName, java.lang.Object[] arguments)
|
static MockProxyMetaClass
|
make(java.lang.Class theClass)
convenience factory method for the most usual case. |
static MockProxyMetaClass
|
make(java.lang.Class theClass, boolean interceptConstruction)
convenience factory method allowing interceptConstruction to be set. |
void
|
setProperty(java.lang.Class aClass, java.lang.Object object, java.lang.String property, java.lang.Object newValue, boolean b, boolean b1)
|
Field Detail |
---|
public final boolean interceptConstruction
Method Detail |
---|
public java.lang.Object MockProxyMetaClass(MetaClassRegistry registry, java.lang.Class theClass, MetaClass adaptee)
adaptee
- the MetaClass to decorate with interceptability
public java.lang.Object MockProxyMetaClass(MetaClassRegistry registry, java.lang.Class theClass, MetaClass adaptee, boolean interceptConstruction)
adaptee
- the MetaClass to decorate with interceptability
public java.lang.Object getProperty(java.lang.Class aClass, java.lang.Object object, java.lang.String property, boolean b, boolean b1)
public java.lang.Object invokeConstructor(java.lang.Object[] arguments)
public java.lang.Object invokeMethod(java.lang.Object object, java.lang.String methodName, java.lang.Object[] arguments)
public java.lang.Object invokeStaticMethod(java.lang.Object object, java.lang.String methodName, java.lang.Object[] arguments)
public static MockProxyMetaClass make(java.lang.Class theClass)
public static MockProxyMetaClass make(java.lang.Class theClass, boolean interceptConstruction)
public void setProperty(java.lang.Class aClass, java.lang.Object object, java.lang.String property, java.lang.Object newValue, boolean b, boolean b1)
Groovy Documentation