edu.stanford.nlp.classify
Class Feature

java.lang.Object
  |
  +--edu.stanford.nlp.classify.Feature

public class Feature
extends Object

A wrapper for a String which allows you to add other attributes, such as weights, to a Feature.


Constructor Summary
Feature(String value)
          Constructor takes a String and creates a Feature.
 
Method Summary
 boolean equals(Object f)
          Returns true if f is equal to me
 String getValue()
          Returns my String value
 int hashCode()
          Allows Features to be hashed and retrieved.
 String toString()
          Used to print a Feature.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Feature

public Feature(String value)
Constructor takes a String and creates a Feature.

Method Detail

getValue

public String getValue()
Returns my String value


toString

public String toString()
Used to print a Feature.

Overrides:
toString in class Object

equals

public boolean equals(Object f)
Returns true if f is equal to me

Overrides:
equals in class Object

hashCode

public int hashCode()
Allows Features to be hashed and retrieved.

Overrides:
hashCode in class Object


Stanford NLP Group