public class

SingletonMetadataAwareAspectInstanceFactory

extends SingletonAspectInstanceFactory
implements MetadataAwareAspectInstanceFactory
java.lang.Object
   ↳ org.springframework.aop.aspectj.SingletonAspectInstanceFactory
     ↳ org.springframework.aop.aspectj.annotation.SingletonMetadataAwareAspectInstanceFactory

Class Overview

Implementation of MetadataAwareAspectInstanceFactory that is backed by a specified singleton object, returning the same instance for every getAspectInstance() call.

Summary

[Expand]
Inherited Constants
From interface org.springframework.core.Ordered
Public Constructors
SingletonMetadataAwareAspectInstanceFactory(Object aspectInstance, String aspectName)
Create a new SingletonMetadataAwareAspectInstanceFactory for the given aspect.
Public Methods
final AspectMetadata getAspectMetadata()
Return the AspectJ AspectMetadata for this factory's aspect.
Protected Methods
int getOrderForAspectClass(Class<?> aspectClass)
Check whether the aspect class carries an Order annotation, falling back to Ordered.LOWEST_PRECEDENCE.
[Expand]
Inherited Methods
From class org.springframework.aop.aspectj.SingletonAspectInstanceFactory
From class java.lang.Object
From interface org.springframework.aop.aspectj.AspectInstanceFactory
From interface org.springframework.aop.aspectj.annotation.MetadataAwareAspectInstanceFactory
From interface org.springframework.core.Ordered

Public Constructors

public SingletonMetadataAwareAspectInstanceFactory (Object aspectInstance, String aspectName)

Create a new SingletonMetadataAwareAspectInstanceFactory for the given aspect.

Parameters
aspectInstance the singleton aspect instance
aspectName the name of the aspect

Public Methods

public final AspectMetadata getAspectMetadata ()

Return the AspectJ AspectMetadata for this factory's aspect.

Returns
  • the aspect metadata

Protected Methods

protected int getOrderForAspectClass (Class<?> aspectClass)

Check whether the aspect class carries an Order annotation, falling back to Ordered.LOWEST_PRECEDENCE.

Parameters
aspectClass the aspect class
See Also