Class AopConstellation
java.lang.Object
enterprises.iwakura.sigewine.core.extension.SigewineConstellation
enterprises.iwakura.sigewine.aop.extension.AopConstellation
public class AopConstellation
extends enterprises.iwakura.sigewine.core.extension.SigewineConstellation
AOP extension for Sigewine that creates proxies for beans with annotated methods.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final net.bytebuddy.ByteBuddyByteBuddy instance for creating proxies.protected final Map<Class<? extends Annotation>, MethodWrapper<? extends Annotation>> Map of method wrappers for different annotations.Fields inherited from class enterprises.iwakura.sigewine.core.extension.SigewineConstellation
priority -
Constructor Summary
ConstructorsConstructorDescriptionAopConstellation(int priority) Creates a new AopConstellation with specified priority. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddMethodWrapper(MethodWrapper<?> methodWrapper) Adds a method wrapper to the method wrapper map.protected Collection<MethodWrapper<?>> getMethodWrappersForObject(Object bean, Map<Class<? extends Annotation>, MethodWrapper<? extends Annotation>> methodWrapperMap) Returns a list of method wrappers for the given object that should be used.voidprocessBeans(enterprises.iwakura.sigewine.core.Sigewine sigewine) Methods inherited from class enterprises.iwakura.sigewine.core.extension.SigewineConstellation
getPriority
-
Field Details
-
byteBuddy
protected final net.bytebuddy.ByteBuddy byteBuddyByteBuddy instance for creating proxies. -
methodWrapperMap
protected final Map<Class<? extends Annotation>,MethodWrapper<? extends Annotation>> methodWrapperMapMap of method wrappers for different annotations. The key is the annotation class, and the value is the method wrapper for that annotation.
-
-
Constructor Details
-
AopConstellation
public AopConstellation(int priority) Creates a new AopConstellation with specified priority.- Parameters:
priority- Priority of the constellation, lower values are processed first
-
-
Method Details
-
addMethodWrapper
Adds a method wrapper to the method wrapper map.- Parameters:
methodWrapper- Method wrapper to add
-
processBeans
public void processBeans(enterprises.iwakura.sigewine.core.Sigewine sigewine) - Specified by:
processBeansin classenterprises.iwakura.sigewine.core.extension.SigewineConstellation
-
getMethodWrappersForObject
protected Collection<MethodWrapper<?>> getMethodWrappersForObject(Object bean, Map<Class<? extends Annotation>, MethodWrapper<? extends Annotation>> methodWrapperMap) Returns a list of method wrappers for the given object that should be used.- Parameters:
bean- Object to get the wrappers formethodWrapperMap- Map of method wrappers to use- Returns:
- List of method wrappers for the object
-