public class DecisionTableHashKey extends java.lang.Object implements java.io.Serializable, RevisionHandler
Constructor and Description |
---|
DecisionTableHashKey(double[] t)
Constructor for a hashKey
|
DecisionTableHashKey(Instance t,
int numAtts,
boolean ignoreClass)
Constructor for a hashKey
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object b)
Tests if two instances are equal
|
java.lang.String |
getRevision()
Returns the revision string.
|
int |
hashCode()
Calculates a hash code
|
void |
print_hash_code()
Prints the hash code
|
java.lang.String |
toString(Instances t,
int maxColWidth)
Convert a hash entry to a string
|
public DecisionTableHashKey(Instance t, int numAtts, boolean ignoreClass) throws java.lang.Exception
t
- an instance from which to generate a keynumAtts
- the number of attributesignoreClass
- if true treat the class as a normal attributejava.lang.Exception
- if something goes wrongpublic DecisionTableHashKey(double[] t)
t
- an array of feature valuespublic java.lang.String toString(Instances t, int maxColWidth)
t
- the set of instancesmaxColWidth
- width to make the fieldspublic int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object b)
equals
in class java.lang.Object
b
- a key to compare withpublic void print_hash_code()
public java.lang.String getRevision()
getRevision
in interface RevisionHandler