类 SingletonAspectInstanceFactory
java.lang.Object
infra.aop.aspectj.SingletonAspectInstanceFactory
- 所有已实现的接口:
AspectInstanceFactory,infra.core.Ordered,Serializable
public class SingletonAspectInstanceFactory
extends Object
implements AspectInstanceFactory, Serializable
Implementation of
AspectInstanceFactory that is backed by a
specified singleton object, returning the same instance for every
getAspectInstance() call.- 从以下版本开始:
- 4.0
- 作者:
- Rod Johnson, Juergen Hoeller
- 另请参阅:
-
字段概要
字段从接口继承的字段 infra.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE -
构造器概要
构造器构造器说明SingletonAspectInstanceFactory(Object aspectInstance) Create a new SingletonAspectInstanceFactory for the given aspect instance. -
方法概要
修饰符和类型方法说明Expose the aspect class loader that this factory uses.final ObjectCreate an instance of this factory's aspect.intgetOrder()Determine the order for this factory's aspect instance, either an instance-specific order expressed through implementing theOrderedinterface, or a fallback order.protected intgetOrderForAspectClass(Class<?> aspectClass) Determine a fallback order for the case that the aspect instance does not express an instance-specific order through implementing theOrderedinterface.
-
字段详细资料
-
aspectInstance
-
-
构造器详细资料
-
SingletonAspectInstanceFactory
Create a new SingletonAspectInstanceFactory for the given aspect instance.- 参数:
aspectInstance- the singleton aspect instance
-
-
方法详细资料
-
getAspectInstance
从接口复制的说明:AspectInstanceFactoryCreate an instance of this factory's aspect.- 指定者:
getAspectInstance在接口中AspectInstanceFactory- 返回:
- the aspect instance (never
null)
-
getAspectClassLoader
从接口复制的说明:AspectInstanceFactoryExpose the aspect class loader that this factory uses.- 指定者:
getAspectClassLoader在接口中AspectInstanceFactory- 返回:
- the aspect class loader (or
nullfor the bootstrap loader) - 另请参阅:
-
ClassUtils.getDefaultClassLoader()
-
getOrder
public int getOrder()Determine the order for this factory's aspect instance, either an instance-specific order expressed through implementing theOrderedinterface, or a fallback order.- 指定者:
getOrder在接口中infra.core.Ordered- 另请参阅:
-
getOrderForAspectClass
Determine a fallback order for the case that the aspect instance does not express an instance-specific order through implementing theOrderedinterface.The default implementation simply returns
Ordered.LOWEST_PRECEDENCE.- 参数:
aspectClass- the aspect class
-