|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--hcrypto.analyzer.TextUtilities
Method Summary | |
static java.lang.String |
cleanString(java.lang.String s)
This method removes punctuation and returns a space delimited string. |
static int |
countTokens(java.lang.String text)
countTokens() counts the tokens (words) in the text. |
static int |
countWords(java.lang.String text)
countWords() counts the number of words in the text by looking up each token in the current dictionary |
static int |
countWordsForPattern(java.lang.String pattern)
countWordsForPattern() counts the number of words in the current dictionary that match the pattern |
static double |
evaluate(java.lang.String text,
java.lang.StringBuffer usedLetters)
countWords() counts the number of words in the text by looking up each token in the current dictionary. |
static Dictionary |
getDictionary()
This method returns the English frequency of a given character. |
static PatternDictionary |
getPatternDictionary()
|
static java.lang.String |
getUnusedLetters(java.lang.String s)
|
static boolean |
isAWord(java.lang.String word)
|
static java.lang.String |
makePattern(java.lang.String s)
This method returns a pattern of the string. |
static java.lang.String |
removeDuplicates(java.lang.String s)
removeDuplicates() removes duplicate tokens from a string |
static java.lang.String |
removeNonAlphabetics(java.lang.String s,
Alphabet a)
This method removes all characters not in the alphabet from the string. |
static java.lang.String |
removeWhiteSpace(java.lang.String s)
This method removes the whitespace from a String. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static Dictionary getDictionary()
public static PatternDictionary getPatternDictionary()
public static boolean isAWord(java.lang.String word)
public static int countTokens(java.lang.String text)
text
- -- a space-delimited stringpublic static int countWordsForPattern(java.lang.String pattern)
pattern
- -- a string of the form 1231, 1223, etc.public static java.lang.String removeDuplicates(java.lang.String s)
public static java.lang.String getUnusedLetters(java.lang.String s)
public static int countWords(java.lang.String text)
public static double evaluate(java.lang.String text, java.lang.StringBuffer usedLetters)
public static java.lang.String removeWhiteSpace(java.lang.String s)
public static java.lang.String cleanString(java.lang.String s)
public static java.lang.String removeNonAlphabetics(java.lang.String s, Alphabet a)
public static java.lang.String makePattern(java.lang.String s)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |