Package org.eclipse.sisu.inject
Interface AnnotatedSource
-
- All Known Implementing Classes:
DescriptionSource
,HiddenSource
,PrioritySource
public interface AnnotatedSource
Binding source locations can implement this interface to supply annotations to theBeanLocator
.- See Also:
Binder.withSource(Object)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description <T extends java.lang.annotation.Annotation>
TgetAnnotation(com.google.inject.Binding<?> binding, java.lang.Class<T> annotationType)
Returns the annotation of the given type that is associated with the binding.
-
-
-
Method Detail
-
getAnnotation
<T extends java.lang.annotation.Annotation> T getAnnotation(com.google.inject.Binding<?> binding, java.lang.Class<T> annotationType)
Returns the annotation of the given type that is associated with the binding.- Parameters:
binding
- The bindingannotationType
- The annotation type- Returns:
- The associated annotation;
null
if no such annotation exists
-
-