|
Errai 3.0.1-SNAPSHOT | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface AnnotationComparator<T extends Annotation>
A simple comparator interface used by the QualifierEqualityFactory
generator to create comparators for
testing the equality of qualifiers at runtime.
NOTE: This interface is only for tested the attribute-equality of like-typed annotations. For instance, you can only compare an annotation of type Foo with another annotation of type Foo. You cannot compare the equality of Foo with Bar. Attempting to do so will simply result in a ClassCastException.
Method Summary | |
---|---|
int |
hashCodeOf(T a1)
Creates a consistent hashCode based on the attribute values of the annotation. |
boolean |
isEqual(T a1,
T a2)
Tests the equality of two qualifiers. |
Method Detail |
---|
boolean isEqual(T a1, T a2)
a1
- an annotation to be compared. cannot be null.a2
- an annotation to be compared. cannot be null.
int hashCodeOf(T a1)
a1
- the annotation to have a hashCode generated for. cannot be null.
|
Errai 3.0.1-SNAPSHOT | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |