Class ScopedInstances
java.lang.Object
org.microbean.scopelet.ScopedInstances
- All Implemented Interfaces:
Instances
An
Instances implementation that is based on scopes.- Author:
- Laird Nelson
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionScopedInstances(Domain domain, Qualifiers bq, Qualifiers sq, Scopes scopes, AnnotationMirror considerActiveness) Creates a newScopedInstances. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturnstrueif and only if the suppliedIdis proxiable.final Selectable<Annotated<? extends AnnotatedConstruct>, Bean<?>> selectableOf(Selectable<? super Annotated<? extends AnnotatedConstruct>, Bean<?>> selectable) Returns aSelectable<AnnotatedConstruct, Bean<?>>that properly considers the fact that aScopeletmay be active or inactive at any point for any reason.final <I> Supplier<? extends I>
-
Constructor Details
-
ScopedInstances
public ScopedInstances(Domain domain, Qualifiers bq, Qualifiers sq, Scopes scopes, AnnotationMirror considerActiveness) Creates a newScopedInstances.- Parameters:
domain- a non-nullDomainbq- a non-nullQualifierssq- a non-nullQualifiersscopes- a non-nullScopesconsiderActiveness- anAnnotationMirrorused to signal that activeness should be taken into consideration during typesafe resolution; may benull- Throws:
NullPointerException- if any argument isnull
-
-
Method Details
-
proxiable
-
selectableOf
public final Selectable<Annotated<? extends AnnotatedConstruct>, Bean<?>> selectableOf(Selectable<? super Annotated<? extends AnnotatedConstruct>, Bean<?>> selectable) Returns aSelectable<AnnotatedConstruct, Bean<?>>that properly considers the fact that aScopeletmay be active or inactive at any point for any reason.- Parameters:
selectable- aSelectablethat will be used for allAnnotatedConstructs other thanScopelettypes being sought for the purpose of instantiating or acquiring contextual instances; must not benull- Returns:
- a non-
nullSelectable - Throws:
NullPointerException- if any argument isnull
-
supplier
-