Package nl._42.beanie
Class BeanBuildCommandAdvice
java.lang.Object
nl._42.beanie.BeanBuildCommandAdvice
- All Implemented Interfaces:
org.aopalliance.aop.Advice
,org.aopalliance.intercept.Interceptor
,org.aopalliance.intercept.MethodInterceptor
public final class BeanBuildCommandAdvice
extends Object
implements org.aopalliance.intercept.MethodInterceptor
Appends bean building logic to builders, allowing custom builder interfaces.
Whenever a custom method is invoked, such as
withName("henk")
we will
automatically decorate the bean with an "name" property value of "henk".
Providing no argument, such as withName()
, we decorate the bean
with a generated "name" property value. The property value is generated using
the same bean builder.
- Since:
- Feb 14, 2014
- Author:
- Jeroen van Schagen
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
BeanBuildCommandAdvice
-
-
Method Details
-
setProxy
Binds this advice to a proxy.- Parameters:
proxy
- the new proxy
-
invoke
- Specified by:
invoke
in interfaceorg.aopalliance.intercept.MethodInterceptor
- Throws:
Throwable
-