- java.lang.Object
-
- com.itextpdf.text.pdf.hyphenation.Hyphenator
-
public class Hyphenator extends java.lang.ObjectThis class is the main entry point to the hyphenation package. You can use only the static methods or create an instance.- Author:
- Carlos Villegas
-
-
Constructor Summary
Constructors Constructor Description Hyphenator(java.lang.String lang, java.lang.String country, int leftMin, int rightMin)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static HyphenationTreegetFileHyphenationTree(java.lang.String key)static HyphenationTreegetHyphenationTree(java.lang.String lang, java.lang.String country)static java.lang.StringgetHyphenDir()Getter for property hyphenDir.static HyphenationTreegetResourceHyphenationTree(java.lang.String key)Hyphenationhyphenate(char[] word, int offset, int len)Hyphenationhyphenate(java.lang.String word)static Hyphenationhyphenate(java.lang.String lang, java.lang.String country, char[] word, int offset, int len, int leftMin, int rightMin)static Hyphenationhyphenate(java.lang.String lang, java.lang.String country, java.lang.String word, int leftMin, int rightMin)static voidsetHyphenDir(java.lang.String _hyphenDir)Setter for property hyphenDir.voidsetLanguage(java.lang.String lang, java.lang.String country)voidsetMinPushCharCount(int min)voidsetMinRemainCharCount(int min)
-
-
-
Method Detail
-
getHyphenationTree
public static HyphenationTree getHyphenationTree(java.lang.String lang, java.lang.String country)
- Parameters:
lang-country-- Returns:
- the hyphenation tree
-
getResourceHyphenationTree
public static HyphenationTree getResourceHyphenationTree(java.lang.String key)
- Parameters:
key-- Returns:
- a hyphenation tree
-
getFileHyphenationTree
public static HyphenationTree getFileHyphenationTree(java.lang.String key)
- Parameters:
key-- Returns:
- a hyphenation tree
-
hyphenate
public static Hyphenation hyphenate(java.lang.String lang, java.lang.String country, java.lang.String word, int leftMin, int rightMin)
- Parameters:
lang-country-word-leftMin-rightMin-- Returns:
- a hyphenation object
-
hyphenate
public static Hyphenation hyphenate(java.lang.String lang, java.lang.String country, char[] word, int offset, int len, int leftMin, int rightMin)
- Parameters:
lang-country-word-offset-len-leftMin-rightMin-- Returns:
- a hyphenation object
-
setMinRemainCharCount
public void setMinRemainCharCount(int min)
- Parameters:
min-
-
setMinPushCharCount
public void setMinPushCharCount(int min)
- Parameters:
min-
-
setLanguage
public void setLanguage(java.lang.String lang, java.lang.String country)- Parameters:
lang-country-
-
hyphenate
public Hyphenation hyphenate(char[] word, int offset, int len)
- Parameters:
word-offset-len-- Returns:
- a hyphenation object
-
hyphenate
public Hyphenation hyphenate(java.lang.String word)
- Parameters:
word-- Returns:
- a hyphenation object
-
getHyphenDir
public static java.lang.String getHyphenDir()
Getter for property hyphenDir.- Returns:
- Value of property hyphenDir.
-
setHyphenDir
public static void setHyphenDir(java.lang.String _hyphenDir)
Setter for property hyphenDir.- Parameters:
_hyphenDir- New value of property hyphenDir.
-
-