DeterminableImports

Interface that can be implemented by ImportSelector and ImportBeanDefinitionRegistrar implementations when they can determine imports early. The ImportSelector and ImportBeanDefinitionRegistrar interfaces are quite flexible which can make it hard to tell exactly what bean definitions they will add. This interface should be used when an implementation consistently results in the same imports, given the same source.

Using DeterminableImports is particularly useful when working with Spring's testing support. It allows for better generation of ApplicationContext cache keys.

Author

Phillip Webb

Andy Wilkinson

Since

1.5.0

Functions

Link copied to clipboard
abstract fun determineImports(metadata: AnnotationMetadata): Set<Any>
Return a set of objects that represent the imports.