Class ImportCandidates
java.lang.Object
org.springframework.boot.context.annotation.ImportCandidates
Contains
@Configuration import candidates, usually auto-configurations.
The load(Class, ClassLoader) method can be used to discover the import
candidates.- Since:
- 2.7.0
- Author:
- Moritz Halbritter, Scott Frederick
-
Method Summary
Modifier and TypeMethodDescriptionReturns the list of loaded import candidates.iterator()static ImportCandidatesload(Class<?> annotation, @Nullable ClassLoader classLoader) Loads the names of import candidates from the classpath.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Iterable
forEach, spliterator
-
Method Details
-
iterator
-
getCandidates
-
load
Loads the names of import candidates from the classpath. The names of the import candidates are stored in files namedMETA-INF/spring/full-qualified-annotation-name.importson the classpath. Every line contains the full qualified name of the candidate class. Comments are supported using the # character.- Parameters:
annotation- annotation to loadclassLoader- class loader to use for loading- Returns:
- list of names of annotated classes
-