org.springframework.core.type.filter
Class AspectJTypeFilter

java.lang.Object
  extended by org.springframework.core.type.filter.AspectJTypeFilter
All Implemented Interfaces:
TypeFilter

public class AspectJTypeFilter
extends java.lang.Object
implements TypeFilter

Type filter that uses AspectJ type pattern for matching.

A critical implementation details of this type filter is that it does not load the class being examined to match with a type pattern.

Since:
2.5
Author:
Ramnivas Laddad, Juergen Hoeller

Field Summary
private  TypePattern typePattern
           
private  World world
           
 
Constructor Summary
AspectJTypeFilter(java.lang.String typePatternExpression, java.lang.ClassLoader classLoader)
           
 
Method Summary
 boolean match(MetadataReader metadataReader, MetadataReaderFactory metadataReaderFactory)
          Determine whether this filter matches for the class described by the given metadata.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

world

private final World world

typePattern

private final TypePattern typePattern
Constructor Detail

AspectJTypeFilter

public AspectJTypeFilter(java.lang.String typePatternExpression,
                         java.lang.ClassLoader classLoader)
Method Detail

match

public boolean match(MetadataReader metadataReader,
                     MetadataReaderFactory metadataReaderFactory)
              throws java.io.IOException
Description copied from interface: TypeFilter
Determine whether this filter matches for the class described by the given metadata.

Specified by:
match in interface TypeFilter
Parameters:
metadataReader - the metadata reader for the target class
metadataReaderFactory - a factory for obtaining metadata readers for other classes (such as superclasses and interfaces)
Returns:
whether this filter matches
Throws:
java.io.IOException - in case of I/O failure when reading metadata