Class ConsistencySubsetEval.hashKey

java.lang.Object
weka.attributeSelection.ConsistencySubsetEval.hashKey
All Implemented Interfaces:
Serializable, RevisionHandler
Enclosing class:
ConsistencySubsetEval

public class ConsistencySubsetEval.hashKey extends Object implements Serializable, RevisionHandler
Class providing keys to the hash table.
See Also:
  • Constructor Details

    • hashKey

      public hashKey(Instance t, int numAtts) throws Exception
      Constructor for a hashKey
      Parameters:
      t - an instance from which to generate a key
      numAtts - the number of attributes
      Throws:
      Exception - if something goes wrong
    • hashKey

      public hashKey(double[] t)
      Constructor for a hashKey
      Parameters:
      t - an array of feature values
  • Method Details

    • toString

      public String toString(Instances t, int maxColWidth)
      Convert a hash entry to a string
      Parameters:
      t - the set of instances
      maxColWidth - width to make the fields
      Returns:
      the hash entry as string
    • hashCode

      public int hashCode()
      Calculates a hash code
      Overrides:
      hashCode in class Object
      Returns:
      the hash code as an integer
    • equals

      public boolean equals(Object b)
      Tests if two instances are equal
      Overrides:
      equals in class Object
      Parameters:
      b - a key to compare with
      Returns:
      true if the objects are equal
    • getRevision

      public String getRevision()
      Returns the revision string.
      Specified by:
      getRevision in interface RevisionHandler
      Returns:
      the revision