Interface EquivalenceStrategy
-
- All Known Implementing Classes:
ParameterizedEquivalenceStrategy
public interface EquivalenceStrategy
A strategy used to determine equivalence of prism items and values. This is quite generic interface. We expect that usually it will not be implemented directly, because comparing prism structures is a complex undertaking. The usual approach will be using ParameterizedEquivalenceStrategy that contains a set of parameters that drive equals/hashCode methods built into prism structures. However, if anyone would need the ultimate flexibility, he is free to implement this interface from scratch. (Note that not all methods in prism API accept this generic form of equivalence strategy. For example, diff(..) methods are limited to ParameterizedEquivalenceStrategy at least for now.)
-
-
Field Summary
Fields Modifier and Type Field Description static ParameterizedEquivalenceStrategy
IGNORE_METADATA
static ParameterizedEquivalenceStrategy
IGNORE_METADATA_CONSIDER_DIFFERENT_IDS
static ParameterizedEquivalenceStrategy
LITERAL
static ParameterizedEquivalenceStrategy
LITERAL_IGNORE_METADATA
static ParameterizedEquivalenceStrategy
NOT_LITERAL
static ParameterizedEquivalenceStrategy
REAL_VALUE
static ParameterizedEquivalenceStrategy
REAL_VALUE_CONSIDER_DIFFERENT_IDS
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
equals(Item<?,?> first, Item<?,?> second)
boolean
equals(PrismValue first, PrismValue second)
int
hashCode(Item<?,?> item)
int
hashCode(PrismValue value)
-
-
-
Field Detail
-
LITERAL
static final ParameterizedEquivalenceStrategy LITERAL
-
NOT_LITERAL
static final ParameterizedEquivalenceStrategy NOT_LITERAL
-
IGNORE_METADATA
static final ParameterizedEquivalenceStrategy IGNORE_METADATA
-
IGNORE_METADATA_CONSIDER_DIFFERENT_IDS
static final ParameterizedEquivalenceStrategy IGNORE_METADATA_CONSIDER_DIFFERENT_IDS
-
LITERAL_IGNORE_METADATA
static final ParameterizedEquivalenceStrategy LITERAL_IGNORE_METADATA
-
REAL_VALUE
static final ParameterizedEquivalenceStrategy REAL_VALUE
-
REAL_VALUE_CONSIDER_DIFFERENT_IDS
static final ParameterizedEquivalenceStrategy REAL_VALUE_CONSIDER_DIFFERENT_IDS
-
-
Method Detail
-
equals
boolean equals(PrismValue first, PrismValue second)
-
hashCode
int hashCode(Item<?,?> item)
-
hashCode
int hashCode(PrismValue value)
-
-