public class GemFireComponentClassTypeScanner extends Object implements Iterable<String>
GemFireComponentClassTypeScanner class is a classpath component scanner used to search
for GemFire components based on Class type.Iterable,
ConfigurableApplicationContext,
ClassPathScanningCandidateComponentProvider,
Environment| Modifier and Type | Field and Description |
|---|---|
protected org.apache.commons.logging.Log |
log |
| Modifier | Constructor and Description |
|---|---|
protected |
GemFireComponentClassTypeScanner(Set<String> basePackages)
Constructs an instance of the
GemFireComponentClassTypeScanner initialized with
the given Set of base packages to scan. |
| Modifier and Type | Method and Description |
|---|---|
static GemFireComponentClassTypeScanner |
from(Iterable<String> basePackages)
Factory method to construct an instance of the
GemFireComponentClassTypeScanner initialized with
the given Iterable of base packages to scan. |
static GemFireComponentClassTypeScanner |
from(String... basePackages)
Factory method to construct an instance of the
GemFireComponentClassTypeScanner initialized with
the given array of base packages to scan. |
protected ConfigurableApplicationContext |
getApplicationContext()
Returns a reference to the Spring
ApplicationContext. |
protected Set<String> |
getBasePackages()
Returns an unmodifiable
Set of base packages to scan for GemFire components. |
protected ClassLoader |
getEntityClassLoader()
Returns a reference to the
ClassLoader to find and load GemFire application persistent entity classes. |
protected Environment |
getEnvironment()
Returns a reference to the Spring
Environment in which the Spring GemFire application is running. |
protected Iterable<TypeFilter> |
getExcludes()
Returns a collection of
TypeFilters used to exclude types found
during the classpath component scan. |
protected Iterable<TypeFilter> |
getIncludes()
Returns a collection of
TypeFilters used to include (match) types found
during the classpath component scan. |
Iterator<String> |
iterator() |
protected ClassPathScanningCandidateComponentProvider |
newClassPathScanningCandidateComponentProvider()
Constructs a new instance of the
ClassPathScanningCandidateComponentProvider initialized with
no default filters. |
protected ClassPathScanningCandidateComponentProvider |
newClassPathScanningCandidateComponentProvider(boolean useDefaultFilters)
Constructs a new instance of the
ClassPathScanningCandidateComponentProvider initialized with
the useDefaultFilters boolean value to indicate whether to use default values or not. |
Set<Class<?>> |
scan()
Scans the
Set of base packages searching for GemFire application components accepted by the filters
of this scanner. |
GemFireComponentClassTypeScanner |
with(ClassLoader entityClassLoader) |
GemFireComponentClassTypeScanner |
with(ConfigurableApplicationContext applicationContext) |
GemFireComponentClassTypeScanner |
withExcludes(Iterable<TypeFilter> excludes) |
GemFireComponentClassTypeScanner |
withExcludes(TypeFilter... excludes) |
GemFireComponentClassTypeScanner |
withIncludes(Iterable<TypeFilter> includes) |
GemFireComponentClassTypeScanner |
withIncludes(TypeFilter... includes) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorprotected GemFireComponentClassTypeScanner(Set<String> basePackages)
GemFireComponentClassTypeScanner initialized with
the given Set of base packages to scan.basePackages - Set of base packages to scan for GemFire component clases.IllegalArgumentException - if the Set is null or empty.Setpublic static GemFireComponentClassTypeScanner from(String... basePackages)
GemFireComponentClassTypeScanner initialized with
the given array of base packages to scan.basePackages - array of base packages to scan for GemFire components.GemFireComponentClassTypeScanner.IllegalArgumentException - if the array of base packages is null or empty.GemFireComponentClassTypeScanner(Set)public static GemFireComponentClassTypeScanner from(Iterable<String> basePackages)
GemFireComponentClassTypeScanner initialized with
the given Iterable of base packages to scan.basePackages - Iterable of base packages to scan for GemFire components.GemFireComponentClassTypeScanner.IllegalArgumentException - if the Iterable of base packages is null or empty.GemFireComponentClassTypeScanner(Set)protected ConfigurableApplicationContext getApplicationContext()
ApplicationContext.ApplicationContext.ConfigurableApplicationContextprotected Set<String> getBasePackages()
Set of base packages to scan for GemFire components.Set of base packages to scan for GemFire components.protected ClassLoader getEntityClassLoader()
ClassLoader to find and load GemFire application persistent entity classes.ClassLoader to find and load GemFire application persistent entity classes.ConfigurableBeanFactory.getBeanClassLoader(),
Thread.getContextClassLoader(),
ClassLoader,
getApplicationContext()protected Environment getEnvironment()
Environment in which the Spring GemFire application is running.Environment.EnvironmentCapable.getEnvironment(),
Environment,
StandardEnvironment,
getApplicationContext()protected Iterable<TypeFilter> getExcludes()
TypeFilters used to exclude types found
during the classpath component scan.TypeFilter objectsTypeFilterprotected Iterable<TypeFilter> getIncludes()
TypeFilters used to include (match) types found
during the classpath component scan.TypeFilter objectsTypeFilterpublic Set<Class<?>> scan()
Set of base packages searching for GemFire application components accepted by the filters
of this scanner.Set of GemFire application component Class types.newClassPathScanningCandidateComponentProvider(boolean),
Setprotected ClassPathScanningCandidateComponentProvider newClassPathScanningCandidateComponentProvider()
ClassPathScanningCandidateComponentProvider initialized with
no default filters.ClassPathScanningCandidateComponentProvider.ClassPathScanningCandidateComponentProvider,
newClassPathScanningCandidateComponentProvider(boolean)protected ClassPathScanningCandidateComponentProvider newClassPathScanningCandidateComponentProvider(boolean useDefaultFilters)
ClassPathScanningCandidateComponentProvider initialized with
the useDefaultFilters boolean value to indicate whether to use default values or not. Additionally,
the exclude/include filters are also set.useDefaultFilters - boolean value to indicate whether to use default filters.ClassPathScanningCandidateComponentProvider.ClassPathScanningCandidateComponentProvider,
newClassPathScanningCandidateComponentProvider(boolean)public GemFireComponentClassTypeScanner with(ClassLoader entityClassLoader)
public GemFireComponentClassTypeScanner with(ConfigurableApplicationContext applicationContext)
public GemFireComponentClassTypeScanner withExcludes(TypeFilter... excludes)
public GemFireComponentClassTypeScanner withExcludes(Iterable<TypeFilter> excludes)
public GemFireComponentClassTypeScanner withIncludes(TypeFilter... includes)
public GemFireComponentClassTypeScanner withIncludes(Iterable<TypeFilter> includes)
Copyright © 2011–2017 Pivotal Software, Inc.. All rights reserved.