public class OrderedIndexStore extends BaseSingleValueIndexStore
| Constructor and Description |
|---|
OrderedIndexStore(IndexCopyBehavior copyOn) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canEvaluate(Class<? extends Predicate> predicateClass) |
Comparable |
canonicalizeQueryArgumentScalar(Comparable value)
Canonicalizes the given value for the purpose of a hash-based lookup.
|
Comparable |
canonicalizeScalarForStorage(Comparable value)
Canonicalizes the given value for storing it in this index store.
|
void |
clear()
Clears the contents of this index by purging all its entries.
|
Set<QueryableEntry> |
evaluate(Predicate predicate,
TypeConverter converter)
Evaluates the given predicate using this index store.
|
Set<QueryableEntry> |
getRecords(Comparable value)
Obtains entries that have indexed attribute value equal to the given
value.
|
Set<QueryableEntry> |
getRecords(Comparable from,
boolean fromInclusive,
Comparable to,
boolean toInclusive)
Obtains entries that have indexed attribute value belonging to the given
range.
|
Set<QueryableEntry> |
getRecords(Comparison comparison,
Comparable searchedValue)
Obtains entries that have indexed attribute value satisfying the given
comparison with the given value.
|
Set<QueryableEntry> |
getRecords(Set<Comparable> values)
Obtains entries that have indexed attribute value equal to one of the
given set of values.
|
boolean |
isEvaluateOnly() |
destroy, insert, remove, updatepublic OrderedIndexStore(IndexCopyBehavior copyOn)
public Comparable canonicalizeQueryArgumentScalar(Comparable value)
IndexStoreThe method is used while performing InPredicate queries to canonicalize the set of values in question, so additional duplicate-eliminating post-processing step can be avoided.
The main difference comparing to BaseIndexStore.canonicalizeScalarForStorage(java.lang.Comparable)
is that this method is specifically designed to support the
canonicalization of transient non-persistent values (think of query
arguments), so a more efficient representation may chosen.
value - the value to canonicalize.public Comparable canonicalizeScalarForStorage(Comparable value)
BaseIndexStore
The method is used by hash indexes to achieve the canonical
representation of mixed-type numeric values, so equals and hashCode logic can work properly.
The main difference comparing to IndexStore.canonicalizeQueryArgumentScalar(java.lang.Comparable)
is that this method is specifically designed to support the
canonicalization of persistent index values (think of map entry attribute
values), so a more suitable value representation may chosen.
value - the value to canonicalize.public void clear()
IndexStorepublic boolean isEvaluateOnly()
true if this index store supports querying only with
IndexStore.evaluate(com.hazelcast.query.Predicate, com.hazelcast.core.TypeConverter) method, false otherwise.public boolean canEvaluate(Class<? extends Predicate> predicateClass)
true if this index store can evaluate a predicate of the
given predicate class, false otherwise.public Set<QueryableEntry> evaluate(Predicate predicate, TypeConverter converter)
IndexStorepredicate - the predicate to evaluate. The predicate is guaranteed
to be evaluable by this index store (canEvaluate
returned true for its class).public Set<QueryableEntry> getRecords(Comparable value)
IndexStorevalue - the value to obtains the entries for.Index.getRecords(Comparable)public Set<QueryableEntry> getRecords(Set<Comparable> values)
IndexStorevalues - the values to obtains the entries for.Index.getRecords(Comparable[])public Set<QueryableEntry> getRecords(Comparison comparison, Comparable searchedValue)
IndexStorecomparison - the comparison to perform.searchedValue - the value to perform the comparison with.Index.getRecords(Comparison, Comparable)public Set<QueryableEntry> getRecords(Comparable from, boolean fromInclusive, Comparable to, boolean toInclusive)
IndexStorefrom - the beginning of the range.fromInclusive - true if the beginning of the range is
inclusive, false otherwise.to - the end of the range.toInclusive - true if the end of the range is inclusive,
false otherwise.Index.getRecords(Comparable, boolean, Comparable, boolean)Copyright © 2020 Hazelcast, Inc.. All Rights Reserved.