Package com.xmlmind.w2x.docx.toxhtml
Class Translator
- java.lang.Object
-
- com.xmlmind.w2x.docx.toxhtml.Translator
-
public final class Translator extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static StringAUTOMATIC_IDS_REGEXA pattern matching most IDs automatically generated by MS-Word.
-
Constructor Summary
Constructors Constructor Description Translator()
-
Method Summary
-
-
-
Field Detail
-
AUTOMATIC_IDS_REGEX
public static final String AUTOMATIC_IDS_REGEX
A pattern matching most IDs automatically generated by MS-Word.Examples:
_TocN,_RefN,BMN,OLE_LINKN,_ENREF_N,_GoBack.- See Also:
- Constant Field Values
-
-
Method Detail
-
setConsole
public void setConsole(Console console)
-
getConsole
public Console getConsole()
-
parseParameters
public void parseParameters(String[] params) throws IllegalArgumentException
- Throws:
IllegalArgumentException
-
setAddColumnNumberPI
public void setAddColumnNumberPI(boolean columnNumberPI)
-
getAddColumnNumberPI
public boolean getAddColumnNumberPI()
-
setXHTMLVersion
public void setXHTMLVersion(XHTMLVersion xhtmlVersion)
-
getXHTMLVersion
public XHTMLVersion getXHTMLVersion()
-
setCharset
public void setCharset(String charset)
-
getCharset
public String getCharset()
-
setForceLang
public void setForceLang(String forceLang)
-
getForceLang
public String getForceLang()
-
setDefaultLang
public void setDefaultLang(String defaultLang)
-
getDefaultLang
public String getDefaultLang()
-
setConvertedImageExtensions
public void setConvertedImageExtensions(String[] extensions)
-
getConvertedImageExtensions
public String[] getConvertedImageExtensions()
-
setResourceDirectoryPath
public void setResourceDirectoryPath(String path)
-
getResourceDirectoryPath
public String getResourceDirectoryPath()
-
setResourcePrefix
public void setResourcePrefix(String prefix)
-
getResourcePrefix
public String getResourcePrefix()
-
setLowerCaseResourceNames
public void setLowerCaseResourceNames(boolean lowerCase)
-
getLowerCaseResourceNames
public boolean getLowerCaseResourceNames()
-
setCreateMathMLObject
public void setCreateMathMLObject(Boolean create)
-
getCreateMathMLObject
public Boolean getCreateMathMLObject()
-
setMarkCustomStyles
public void setMarkCustomStyles(boolean mark)
-
getMarkCustomStyles
public boolean getMarkCustomStyles()
-
setSimplify
public void setSimplify(boolean simplify)
-
getSimplify
public boolean getSimplify()
-
setKeepAllRanges
public void setKeepAllRanges(boolean keep)
-
getKeepAllRanges
public boolean getKeepAllRanges()
-
setAutomaticIds
public void setAutomaticIds(String regex) throws PatternSyntaxException
- Throws:
PatternSyntaxException
-
setAutomaticIdsPattern
public void setAutomaticIdsPattern(Pattern pattern)
-
getAutomaticIdsPattern
public Pattern getAutomaticIdsPattern()
-
translate
public Document translate(File docxFile, File outFile, ResourceDirectory resourceDir) throws IOException
- Throws:
IOException
-
translateToImg
public Element translateToImg(Element drawingOrPict) throws IOException
- Throws:
IOException
-
-