cmu.tawc.data
Class Word.RegexpWord

java.lang.Object
  extended by cmu.tawc.data.Word.WordStub
      extended by cmu.tawc.data.Word.RegexpWord
All Implemented Interfaces:
Word
Enclosing interface:
Word

public static class Word.RegexpWord
extends Word.WordStub


Nested Class Summary
 
Nested classes/interfaces inherited from interface cmu.tawc.data.Word
Word.ComboWord, Word.DashWord, Word.PlainWord, Word.RegexpWord, Word.WordStub
 
Constructor Summary
Word.RegexpWord(java.lang.String word, java.util.Vector<Category> categories)
           
 
Method Summary
 java.lang.String getWordPublicName()
           
 int matches(java.lang.String testWord)
           
 boolean matchesWord(java.lang.String word)
           
 boolean matchesWord(java.lang.String[] words, int index)
          Does this match a word in a sentence?
 java.lang.String toString()
           
 
Methods inherited from class cmu.tawc.data.Word.WordStub
getCategories, getWord
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Word.RegexpWord

public Word.RegexpWord(java.lang.String word,
                       java.util.Vector<Category> categories)
Method Detail

matches

public int matches(java.lang.String testWord)

toString

public java.lang.String toString()
Overrides:
toString in class Word.WordStub

matchesWord

public boolean matchesWord(java.lang.String word)
Returns:
number of times the Word matches the passed in sentence

getWordPublicName

public java.lang.String getWordPublicName()

matchesWord

public boolean matchesWord(java.lang.String[] words,
                           int index)
Description copied from interface: Word
Does this match a word in a sentence? Can match combo words, starting in one place.

Returns: