|
![]() |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.thoughtworks.proxy.toys.decorate.Decorating
public class Decorating
Toy factory to create proxies decorating an object in an AOP style.
An InvocationDecorator is used for the additional functionality. It is called before the original method is called, after the original method was called, after the original method has thrown an exceptionor when an exception occurs, calling the method of the decorated object.
com.thoughtworks.proxy.toys.decorate
Method Summary | |
---|---|
static Object |
object(Class[] types,
Object delegate,
InvocationDecorator decorator)
Create a decorating proxy implementing specific types. |
static Object |
object(Class[] types,
Object delegate,
InvocationDecorator decorator,
ProxyFactory factory)
Create a decorating proxy implementing specific types using a provided ProxyFactory . |
static Object |
object(Class type,
Object delegate,
InvocationDecorator decorator)
Create a decorating proxy implementing a specific type. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static Object object(Class type, Object delegate, InvocationDecorator decorator)
type
- the type of the created proxy.delegate
- the decorated object.decorator
- the decorator instance.
public static Object object(Class[] types, Object delegate, InvocationDecorator decorator)
types
- the types of the created proxy.delegate
- the decorated object.decorator
- the decorator instance.
public static Object object(Class[] types, Object delegate, InvocationDecorator decorator, ProxyFactory factory)
ProxyFactory
.
types
- the types of the created proxy.delegate
- the decorated object.decorator
- the decorator instance.factory
- the ProxyFactory to use for the proxy generation.
|
![]() |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |