public class DefaultCustomScopeRegistry extends Object implements CustomScopeRegistry
CustomScopeRegistry
interface.Modifier | Constructor and Description |
---|---|
protected |
DefaultCustomScopeRegistry(BeanLocator beanLocator) |
Modifier and Type | Method and Description |
---|---|
<T> Optional<BeanRegistration<T>> |
findBeanRegistration(T bean)
Finds A bean registration amongst the active scopes.
|
Optional<CustomScope<?>> |
findDeclaredScope(Argument<?> argument)
Finds the declared scope for the given argument.
|
Optional<CustomScope<?>> |
findDeclaredScope(BeanType<?> beanType)
Finds the declared scope for the given bean type.
|
Optional<CustomScope<?>> |
findScope(Class<? extends Annotation> scopeAnnotation)
Find a custom scope for the given annotation.
|
Optional<CustomScope<?>> |
findScope(String scopeAnnotation)
Find a custom scope for the given annotation.
|
protected DefaultCustomScopeRegistry(BeanLocator beanLocator)
beanLocator
- The bean locatorpublic <T> Optional<BeanRegistration<T>> findBeanRegistration(T bean)
CustomScopeRegistry
findBeanRegistration
in interface CustomScopeRegistry
T
- The bean typebean
- The beanpublic Optional<CustomScope<?>> findDeclaredScope(@NonNull Argument<?> argument)
CustomScopeRegistry
findDeclaredScope
in interface CustomScopeRegistry
argument
- The argumentpublic Optional<CustomScope<?>> findDeclaredScope(@NonNull BeanType<?> beanType)
CustomScopeRegistry
findDeclaredScope
in interface CustomScopeRegistry
beanType
- The bean typepublic Optional<CustomScope<?>> findScope(Class<? extends Annotation> scopeAnnotation)
CustomScopeRegistry
findScope
in interface CustomScopeRegistry
scopeAnnotation
- The scope annotationpublic Optional<CustomScope<?>> findScope(String scopeAnnotation)
CustomScopeRegistry
findScope
in interface CustomScopeRegistry
scopeAnnotation
- The scope annotation