Top Description Fields Constructors Methods
org.springframework.aop.support

public Class IntroductionInfoSupport

extends Object
implements IntroductionInfo, Serializable
Class Inheritance
All Implemented Interfaces
java.io.Serializable, org.springframework.aop.IntroductionInfo
Known Direct Subclasses
org.springframework.aop.support.DelegatePerTargetObjectIntroductionInterceptor, org.springframework.aop.support.DelegatingIntroductionInterceptor
Annotations
@SuppressWarnings:serial
Imports
java.io.IOException, .ObjectInputStream, .Serializable, java.lang.reflect.Method, java.util.LinkedHashSet, .Map, .Set, java.util.concurrent.ConcurrentHashMap, org.aopalliance.intercept.MethodInvocation, org.springframework.aop.IntroductionInfo, org.springframework.util.ClassUtils

Support for implementations of org.springframework.aop.IntroductionInfo.

Allows subclasses to conveniently add all interfaces from a given object, and to suppress interfaces that should not be added. Also allows for querying all introduced interfaces.

Authors
Rod Johnson, Juergen Hoeller

Field Summary

Modifier and TypeField and Description
protected final Set<Class<?>>
private transient Map<Method, Boolean>

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public Class<?>[]
getInterfaces()

Implements org.springframework.aop.IntroductionInfo.getInterfaces.

Return the additional interfaces introduced by this Advisor or Advice.

protected void
implementInterfacesOnObject(Object
the delegate object
delegate
)

Publish all interfaces that the given delegate implements at the proxy level.

public boolean

Returns:

whether the interface is part of this introduction
implementsInterface
(Class<?>
the interface to check
ifc
)

Check whether the specified interfaces is a published introduction interface.

protected final boolean

Returns:

whether the invoked method is on an introduced interface
isMethodOnIntroducedInterface
(MethodInvocation
the method invocation
mi
)

Is this method on an introduced interface?

private void
readObject(ObjectInputStream ois)

This method is implemented only to restore the logger.

public void
suppressInterface(Class<?>
the interface to suppress
ifc
)

Suppress the specified interface, which may have been autodetected due to the delegate implementing it.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

publishedInterfacesback to summary
protected final Set<Class<?>> publishedInterfaces
rememberedMethodsback to summary
private transient Map<Method, Boolean> rememberedMethods

Constructor Detail

IntroductionInfoSupportback to summary
public IntroductionInfoSupport()

Method Detail

getInterfacesback to summary
public Class<?>[] getInterfaces()

Implements org.springframework.aop.IntroductionInfo.getInterfaces.

Doc from org.springframework.aop.IntroductionInfo.getInterfaces.

Return the additional interfaces introduced by this Advisor or Advice.

Returns:Class<?>[]

the introduced interfaces

Annotations
@Override
implementInterfacesOnObjectback to summary
protected void implementInterfacesOnObject(Object delegate)

Publish all interfaces that the given delegate implements at the proxy level.

Parameters
delegate:Object

the delegate object

implementsInterfaceback to summary
public boolean implementsInterface(Class<?> ifc)

Check whether the specified interfaces is a published introduction interface.

Parameters
ifc:Class<?>

the interface to check

Returns:boolean

whether the interface is part of this introduction

isMethodOnIntroducedInterfaceback to summary
protected final boolean isMethodOnIntroducedInterface(MethodInvocation mi)

Is this method on an introduced interface?

Parameters
mi:MethodInvocation

the method invocation

Returns:boolean

whether the invoked method is on an introduced interface

readObjectback to summary
private void readObject(ObjectInputStream ois) throws IOException, ClassNotFoundException

This method is implemented only to restore the logger. We don't make the logger static as that would mean that subclasses would use this class's log category.

suppressInterfaceback to summary
public void suppressInterface(Class<?> ifc)

Suppress the specified interface, which may have been autodetected due to the delegate implementing it. Call this method to exclude internal interfaces from being visible at the proxy level.

Does nothing if the interface is not implemented by the delegate.

Parameters
ifc:Class<?>

the interface to suppress