Package org.eclipse.sisu.inject
Class PrioritySource
java.lang.Object
org.eclipse.sisu.inject.PrioritySource
- All Implemented Interfaces:
Annotation,AnnotatedSource
Implementation of @
Priority that can also act as an @AnnotatedSource.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionClass<? extends Annotation>boolean<T extends Annotation>
TgetAnnotation(com.google.inject.Binding<?> binding, Class<T> annotationType) Returns the annotation of the given type that is associated with the binding.inthashCode()toString()intvalue()
-
Field Details
-
source
-
value
private final int value
-
-
Constructor Details
-
PrioritySource
PrioritySource(Object source, int value) - Parameters:
source- The owning sourcevalue- The priority
-
-
Method Details
-
value
public int value() -
annotationType
- Specified by:
annotationTypein interfaceAnnotation
-
hashCode
public int hashCode()- Specified by:
hashCodein interfaceAnnotation- Overrides:
hashCodein classObject
-
equals
- Specified by:
equalsin interfaceAnnotation- Overrides:
equalsin classObject
-
toString
- Specified by:
toStringin interfaceAnnotation- Overrides:
toStringin classObject
-
getAnnotation
public <T extends Annotation> T getAnnotation(com.google.inject.Binding<?> binding, Class<T> annotationType) Description copied from interface:AnnotatedSourceReturns the annotation of the given type that is associated with the binding.- Specified by:
getAnnotationin interfaceAnnotatedSource- Parameters:
binding- The bindingannotationType- The annotation type- Returns:
- The associated annotation;
nullif no such annotation exists
-