Package com.inet.jorthodictionaries
Class BookUtils
- java.lang.Object
-
- com.inet.jorthodictionaries.BookUtils
-
public class BookUtils extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description BookUtils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static int
calcDiff(java.lang.String word1, java.lang.String word2)
Very simple algorithm to calc the diff betwenn 2 words.(package private) static int
findTemplate(java.lang.String wikiText, java.lang.String tempalateName, int fromIndex)
Find a template name in the wiki text.(package private) static java.util.Properties
parseRule(java.lang.String wikiText, int idxStart, int idxEnd)
Read the information of the template placeholder(package private) static java.util.Properties
parseRule(java.lang.String wikiText, java.lang.String tempalateName, int fromIndex)
Read the information of the template placeholder
-
-
-
Method Detail
-
parseRule
static java.util.Properties parseRule(java.lang.String wikiText, java.lang.String tempalateName, int fromIndex)
Read the information of the template placeholder- Returns:
- null if nothing find
-
parseRule
static java.util.Properties parseRule(java.lang.String wikiText, int idxStart, int idxEnd)
Read the information of the template placeholder
-
findTemplate
static int findTemplate(java.lang.String wikiText, java.lang.String tempalateName, int fromIndex)
Find a template name in the wiki text. the problem are possible whitespaces.- Parameters:
wikiText
-tempalateName
-- Returns:
- the index after the first | or -1.
-
calcDiff
public static int calcDiff(java.lang.String word1, java.lang.String word2)
Very simple algorithm to calc the diff betwenn 2 words.
-
-