edu.stanford.nlp.ie.hmm
Class WordTypeStripper
java.lang.Object
|
+--edu.stanford.nlp.ie.hmm.WordTypeStripper
- All Implemented Interfaces:
- Appliable
- public class WordTypeStripper
- extends Object
- implements Appliable
Appliable that sets the type of a TypedTaggedWord
to 0.
- See Also:
apply(java.lang.Object)
Method Summary |
Object |
apply(Object in)
If in is a TypedTaggedWord, returns a new copy of the
word with the type set to 0. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
WordTypeStripper
public WordTypeStripper()
apply
public Object apply(Object in)
- If in is a TypedTaggedWord, returns a new copy of the
word with the type set to 0. Otherwise returns in directly.
NOTE: Ideally one could just test for HasType and then make
a copy of in and call setType but it's not clear how
to make the copy.
- Specified by:
apply
in interface Appliable
Stanford NLP Group