Package org.leo.unleash.aop
Class FeatureAdvisor
- java.lang.Object
-
- org.leo.unleash.aop.FeatureAdvisor
-
- All Implemented Interfaces:
org.aopalliance.aop.Advice,org.aopalliance.intercept.Interceptor,org.aopalliance.intercept.MethodInterceptor
@Component("features.advisor") public class FeatureAdvisor extends Object implements org.aopalliance.intercept.MethodInterceptor
-
-
Field Summary
Fields Modifier and Type Field Description private org.springframework.context.ApplicationContextapplicationContextprivate static org.slf4j.LoggerLOGGERprivate io.getunleash.Unleashunleash
-
Constructor Summary
Constructors Constructor Description FeatureAdvisor(io.getunleash.Unleash unleash, org.springframework.context.ApplicationContext applicationContext)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private booleancheck(Toggle toggle, org.aopalliance.intercept.MethodInvocation mi)private StringgetExecutedBeanName(org.aopalliance.intercept.MethodInvocation mi)private Class<?>getExecutedClass(org.aopalliance.intercept.MethodInvocation mi)private TogglegetToggleAnnotation(org.aopalliance.intercept.MethodInvocation mi)Objectinvoke(org.aopalliance.intercept.MethodInvocation mi)private ObjectinvokeAlterBean(org.aopalliance.intercept.MethodInvocation mi, String alterBeanName)
-
-
-
Method Detail
-
invoke
public Object invoke(org.aopalliance.intercept.MethodInvocation mi) throws Throwable
- Specified by:
invokein interfaceorg.aopalliance.intercept.MethodInterceptor- Throws:
Throwable
-
invokeAlterBean
private Object invokeAlterBean(org.aopalliance.intercept.MethodInvocation mi, String alterBeanName)
-
check
private boolean check(Toggle toggle, org.aopalliance.intercept.MethodInvocation mi)
-
getExecutedBeanName
private String getExecutedBeanName(org.aopalliance.intercept.MethodInvocation mi)
-
getToggleAnnotation
private Toggle getToggleAnnotation(org.aopalliance.intercept.MethodInvocation mi)
-
getExecutedClass
private Class<?> getExecutedClass(org.aopalliance.intercept.MethodInvocation mi)
-
-