Class GemFireComponentClassTypeScanner
java.lang.Object
org.springframework.data.gemfire.config.annotation.support.GemFireComponentClassTypeScanner
The
GemFireComponentClassTypeScanner
class is a classpath component scanner used to search
for GemFire components based on Class
type.- Since:
- 1.9.0
- Author:
- John Blum
- See Also:
-
Field Summary
-
Constructor Summary
ModifierConstructorDescriptionprotected
GemFireComponentClassTypeScanner
(Set<String> basePackages) Constructs an instance of theGemFireComponentClassTypeScanner
initialized with the givenSet
of base packages to scan. -
Method Summary
Modifier and TypeMethodDescriptionFactory method to construct an instance of theGemFireComponentClassTypeScanner
initialized with the givenIterable
of base packages to scan.Factory method to construct an instance of theGemFireComponentClassTypeScanner
initialized with the given array of base packages to scan.protected ConfigurableApplicationContext
Returns a reference to the SpringApplicationContext
.Returns an unmodifiableSet
of base packages to scan for GemFire components.protected ClassLoader
Returns a reference to theClassLoader
used to find and load GemFire application persistent entity classes.protected Environment
Returns a reference to the SpringEnvironment
in which the Spring GemFire application is running.protected Iterable<TypeFilter>
Returns a collection ofTypeFilters
used to exclude types found during the classpath component scan.protected Iterable<TypeFilter>
Returns a collection ofTypeFilters
used to include (match) types found during the classpath component scan.iterator()
Constructs a new instance of theClassPathScanningCandidateComponentProvider
initialized with no default filters.newClassPathScanningCandidateComponentProvider
(boolean useDefaultFilters) Constructs a new instance of theClassPathScanningCandidateComponentProvider
initialized with theuseDefaultFilters
boolean value to indicate whether to use default values or not.scan()
Scans theSet
of base packages searching for GemFire application components accepted by the filters of this scanner.with
(ClassLoader entityClassLoader) with
(ConfigurableApplicationContext applicationContext) withExcludes
(Iterable<TypeFilter> excludes) withExcludes
(TypeFilter... excludes) withIncludes
(Iterable<TypeFilter> includes) withIncludes
(TypeFilter... includes) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Field Details
-
logger
protected final org.slf4j.Logger logger
-
-
Constructor Details
-
GemFireComponentClassTypeScanner
Constructs an instance of theGemFireComponentClassTypeScanner
initialized with the givenSet
of base packages to scan.- Parameters:
basePackages
-Set
of base packages to scan for GemFire component clases.- Throws:
IllegalArgumentException
- if theSet
is null or empty.- See Also:
-
-
Method Details
-
from
Factory method to construct an instance of theGemFireComponentClassTypeScanner
initialized with the given array of base packages to scan.- Parameters:
basePackages
- array of base packages to scan for GemFire components.- Returns:
- an initialized instance of
GemFireComponentClassTypeScanner
. - Throws:
IllegalArgumentException
- if the array of base packages is null or empty.- See Also:
-
from
Factory method to construct an instance of theGemFireComponentClassTypeScanner
initialized with the givenIterable
of base packages to scan.- Parameters:
basePackages
-Iterable
of base packages to scan for GemFire components.- Returns:
- an initialized instance of
GemFireComponentClassTypeScanner
. - Throws:
IllegalArgumentException
- if theIterable
of base packages is null or empty.- See Also:
-
getApplicationContext
Returns a reference to the SpringApplicationContext
.- Returns:
- a reference to the Spring
ApplicationContext
. - See Also:
-
getBasePackages
Returns an unmodifiableSet
of base packages to scan for GemFire components. -
getEntityClassLoader
Returns a reference to theClassLoader
used to find and load GemFire application persistent entity classes.- Returns:
- the
ClassLoader
used to find and load GemFire application persistent entity classes. - See Also:
-
getEnvironment
Returns a reference to the SpringEnvironment
in which the Spring GemFire application is running.- Returns:
- a reference to the Spring
Environment
. - See Also:
-
getExcludes
Returns a collection ofTypeFilters
used to exclude types found during the classpath component scan.- Returns:
- a collection of
TypeFilter
objects - See Also:
-
getIncludes
Returns a collection ofTypeFilters
used to include (match) types found during the classpath component scan.- Returns:
- a collection of
TypeFilter
objects - See Also:
-
iterator
-
scan
Scans theSet
of base packages searching for GemFire application components accepted by the filters of this scanner. -
newClassPathScanningCandidateComponentProvider
protected ClassPathScanningCandidateComponentProvider newClassPathScanningCandidateComponentProvider()Constructs a new instance of theClassPathScanningCandidateComponentProvider
initialized with no default filters.- Returns:
- a new instance of the
ClassPathScanningCandidateComponentProvider
. - See Also:
-
newClassPathScanningCandidateComponentProvider
protected ClassPathScanningCandidateComponentProvider newClassPathScanningCandidateComponentProvider(boolean useDefaultFilters) Constructs a new instance of theClassPathScanningCandidateComponentProvider
initialized with theuseDefaultFilters
boolean value to indicate whether to use default values or not. Additionally, the exclude/include filters are also set.- Parameters:
useDefaultFilters
- boolean value to indicate whether to use default filters.- Returns:
- a new instance of the
ClassPathScanningCandidateComponentProvider
. - See Also:
-
with
-
with
-
withExcludes
-
withExcludes
-
withIncludes
-
withIncludes
-