public final class IlrHasher
extends java.lang.Object
implements java.io.Serializable
The properties are the size of the internal hash table, an accuracy flag to indicate which internal structure should be used, a constant flag indicating whether the hasher class instances are constant or not, and an ordered flag activating the hasher on relation orders. These properties may have an important influence on the performance of the engine.
By default, a hasher is activated only on an equality relation, is not accurate, and not constant.
There are additional constraints on the properties and the hashing expressions. Please refer to the reference manual.
| Modifier and Type | Field and Description |
|---|---|
static int |
DEFAULT_SIZE |
| Constructor and Description |
|---|
IlrHasher(IlrVariable formalVariable,
IlrValue hashingExpr)
Builds a hasher given its formal parameter and hashing expression.
|
| Modifier and Type | Method and Description |
|---|---|
IlrVariable |
getFormalVariable()
Gets the formal variable of the hasher.
|
IlrValue |
getHashingExpression()
Gets the hashing expression of the hasher.
|
java.lang.String |
getIdentifier()
Gets the identifier of the hasher.
|
int |
getSize()
Gets the size of the internal hash table.
|
boolean |
isAccurate()
Indicates whether the hasher is accurate or not.
|
boolean |
isConstant()
Indicates whether the hasher is constant or not.
|
boolean |
isOrdered()
Indicates whether the hasher is ordered or not.
|
void |
setAccurate(boolean accurate)
Sets the accuracy of the hasher.
|
void |
setConstant(boolean constant)
Sets the constant quality of the hasher.
|
void |
setOrdered(boolean ordered)
Sets the ordered quality of the hasher.
|
void |
setSize(int size)
Sets the size of the internal hash table dedicated to this hasher.
|
public static final int DEFAULT_SIZE
public IlrHasher(IlrVariable formalVariable, IlrValue hashingExpr)
formalVariable - The formal parameter.hashingExpr - The hashing expression.public void setAccurate(boolean accurate)
accurate - true to set the hasher accuracy property.public void setConstant(boolean constant)
constant - true to set the hasher constant property.public void setOrdered(boolean ordered)
ordered - true to set the hasher ordered property.public java.lang.String getIdentifier()
public boolean isAccurate()
true if accurate.public boolean isConstant()
true if constant.public boolean isOrdered()
true if ordered.public void setSize(int size)
size - The size to be set.public int getSize()
public IlrVariable getFormalVariable()
public IlrValue getHashingExpression()
© Copyright IBM Corp. 1987, 2017