public interface BeanEntry<Q extends java.lang.annotation.Annotation,T>
extends java.util.Map.Entry<Q,T>
Q
ualified bean implementations of T
:@Inject Iterable<BeanEntry<Named, Command>> commands;Use this when you want to know more about available beans; especially if you want to avoid creating instances.
BeanLocator
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getDescription()
Returns a human-readable description of the bean; see @
Description . |
java.lang.Class<T> |
getImplementationClass()
Attempts to find the implementation type without creating the bean instance.
|
Q |
getKey()
Returns the @
Qualifier annotation associated with this particular bean. |
javax.inject.Provider<T> |
getProvider()
Returns the underlying
Provider ; may support creation of multiple instances. |
int |
getRank()
Returns the bean's rank; higher ranked beans override lower ranked beans.
|
java.lang.Object |
getSource()
Returns an arbitrary object that indicates where this bean was configured.
|
T |
getValue()
Returns the associated instance of the bean; returns same instance for each call.
|
Q getKey()
Qualifier
annotation associated with this particular bean.T getValue()
javax.inject.Provider<T> getProvider()
Provider
; may support creation of multiple instances.java.lang.String getDescription()
Description
.Description
java.lang.Class<T> getImplementationClass()
null
if the type cannot be determinedjava.lang.Object getSource()
int getRank()
Priority