java.lang.Object sferyx.administration.docxhtmlconverter.DocxHTMLConverter
public class DocxHTMLConverter
General purpose DocxHTML Converter - this class provides fully featured generation of HTML files from various sources containing Docx content.
Field Summary | |
---|---|
static boolean |
debug
|
Constructor Summary | |
---|---|
DocxHTMLConverter()
Creates a new instance of HTMLGenerator |
Method Summary | |
---|---|
void |
addPageBreakToContentBuffer()
Adds a HTML page break to the content buffer and all the content appended after that will be on the next page when printed |
void |
appendDocxToContentBuffer(java.io.File file)
Appends the whole content of the Docx file from the File to the content buffer. |
void |
appendDocxToContentBuffer(java.net.URL file)
Appends the whole content of the Docx file from the given URL to the content buffer. |
void |
appendHTMLContentToContentBuffer(java.lang.String content)
Appends new HTML string to existing content buffer. |
void |
clearContentBuffer()
Closes the content buffer and clears the content. |
java.lang.String |
closeBufferAndGenerateHTML()
Generates the HTML content automatically for given content buffer created prevuiously by using openContentBuffer() and appendContentXXX() methods. |
void |
closeBufferAndGenerateHTML(java.io.OutputStream destinationStream)
Closes the existing content buffer and generates the resulting content from the DocxHTML Converter - it will be saved in the given OutputStream. |
void |
closeBufferAndGenerateHTML(java.lang.String destinationFile)
Generates the HTML content automatically for given content buffer created prevuiously by using openContentBuffer() and appendContentXXX() methods. |
java.lang.String |
generateHTMLFromContent(java.lang.String content)
Generates HTML automatically for given image or HTML content. |
void |
generateHTMLFromContent(java.lang.String content,
java.io.File destinationFile)
Generates html automatically for given html content. |
void |
generateHTMLFromContent(java.lang.String content,
java.io.OutputStream destinationStream)
Generates HTML automatically for given image or html content. |
void |
generateHTMLFromContent(java.lang.String content,
java.lang.String destinationFile)
Generates the HTML automatically for given html content. |
java.lang.String |
generateHTMLFromDocxURL(java.lang.String sourceURL)
Generates HTML automatically for given URL source containing a MS Word Docx file. |
void |
generateHTMLFromDocxURL(java.lang.String sourceURL,
java.io.File destinationFile)
Generates HTML automatically for given URL source containing a MS Word Docx file. |
void |
generateHTMLFromDocxURL(java.lang.String sourceURL,
java.lang.String destinationFile)
Generates HTML automatically for given URL source containing a MS Word Docx file. |
java.lang.String |
generateHTMLFromDocxURL(java.net.URL sourceURL)
Generates HTML automatically for given URL source containing a MS Word Docx file. |
void |
generateHTMLFromDocxURL(java.net.URL sourceURL,
java.io.File destinationFile)
Generates HTML automatically for given URL source containing a MS Word Docx file. |
void |
generateHTMLFromDocxURL(java.net.URL sourceURL,
java.io.OutputStream fos)
Generates HTML automatically for given URL source containing a MS Word Docx file. |
void |
generateHTMLFromURL(java.lang.String sourceURL)
Generates HTML automatically for given URL source. |
void |
generateHTMLFromURL(java.lang.String sourceURL,
java.io.File destinationFile)
Generates HTML automatically for given URL source and saves the result to destinationFile as string. |
void |
generateHTMLFromURL(java.lang.String sourceURL,
java.io.OutputStream destinationStream)
Generates HTML automatically for given URL source and saves the result to the given OutputStream as a string. |
void |
generateHTMLFromURL(java.lang.String sourceURL,
java.lang.String destinationFile)
Generates HTML automatically for given URL source and saves the result to destinationFile as a string. |
java.lang.String |
generateHTMLFromURL(java.net.URL sourceURL)
Generates HTML automatically for given URL source and saves the result will be returned as a String. |
void |
generateHTMLFromURL(java.net.URL sourceURL,
java.io.OutputStream destinationStream)
Generates HTML automatically for given URL source and saves the result to destinationStream as string. |
static void |
main(java.lang.String[] args)
|
void |
openContentBuffer()
Opens the new content buffer for inserting content to be used for dynamic HTML generation. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static boolean debug
Constructor Detail |
---|
public DocxHTMLConverter()
Method Detail |
---|
public void generateHTMLFromURL(java.lang.String sourceURL) throws java.io.UnsupportedEncodingException, java.io.IOException
java.io.UnsupportedEncodingException
java.io.IOException
public void generateHTMLFromURL(java.lang.String sourceURL, java.lang.String destinationFile) throws java.net.MalformedURLException, java.io.UnsupportedEncodingException, java.io.IOException
java.net.MalformedURLException
java.io.UnsupportedEncodingException
java.io.IOException
public void generateHTMLFromURL(java.lang.String sourceURL, java.io.OutputStream destinationStream) throws java.net.MalformedURLException, java.io.UnsupportedEncodingException, java.io.IOException
java.net.MalformedURLException
java.io.UnsupportedEncodingException
java.io.IOException
public void generateHTMLFromURL(java.lang.String sourceURL, java.io.File destinationFile) throws java.net.MalformedURLException, java.io.UnsupportedEncodingException, java.io.IOException
java.net.MalformedURLException
java.io.UnsupportedEncodingException
java.io.IOException
public void generateHTMLFromURL(java.net.URL sourceURL, java.io.OutputStream destinationStream) throws java.io.UnsupportedEncodingException, java.io.IOException
java.io.UnsupportedEncodingException
java.io.IOException
public java.lang.String generateHTMLFromURL(java.net.URL sourceURL) throws java.io.UnsupportedEncodingException, java.io.IOException
java.io.UnsupportedEncodingException
java.io.IOException
public void generateHTMLFromDocxURL(java.lang.String sourceURL, java.lang.String destinationFile) throws java.net.MalformedURLException, java.io.UnsupportedEncodingException, java.io.IOException
java.net.MalformedURLException
java.io.UnsupportedEncodingException
java.io.IOException
public void generateHTMLFromDocxURL(java.lang.String sourceURL, java.io.File destinationFile) throws java.net.MalformedURLException, java.io.UnsupportedEncodingException, java.io.IOException
java.net.MalformedURLException
java.io.UnsupportedEncodingException
java.io.IOException
public void generateHTMLFromDocxURL(java.net.URL sourceURL, java.io.File destinationFile) throws java.io.UnsupportedEncodingException, java.io.IOException
java.io.UnsupportedEncodingException
java.io.IOException
public void generateHTMLFromDocxURL(java.net.URL sourceURL, java.io.OutputStream fos) throws java.io.UnsupportedEncodingException, java.io.IOException
java.io.UnsupportedEncodingException
java.io.IOException
public java.lang.String generateHTMLFromDocxURL(java.net.URL sourceURL) throws java.io.UnsupportedEncodingException, java.io.IOException
java.io.UnsupportedEncodingException
java.io.IOException
public java.lang.String generateHTMLFromDocxURL(java.lang.String sourceURL) throws java.io.UnsupportedEncodingException, java.io.IOException, java.net.MalformedURLException
java.io.UnsupportedEncodingException
java.io.IOException
java.net.MalformedURLException
public void openContentBuffer()
public void appendHTMLContentToContentBuffer(java.lang.String content)
public void appendDocxToContentBuffer(java.net.URL file)
public void appendDocxToContentBuffer(java.io.File file)
public void addPageBreakToContentBuffer()
public void closeBufferAndGenerateHTML(java.io.OutputStream destinationStream) throws java.io.UnsupportedEncodingException, java.io.IOException
java.io.UnsupportedEncodingException
java.io.IOException
public void closeBufferAndGenerateHTML(java.lang.String destinationFile) throws java.io.UnsupportedEncodingException, java.io.IOException
java.io.UnsupportedEncodingException
java.io.IOException
public java.lang.String closeBufferAndGenerateHTML() throws java.io.UnsupportedEncodingException, java.io.IOException
java.io.UnsupportedEncodingException
java.io.IOException
public void clearContentBuffer()
public void generateHTMLFromContent(java.lang.String content, java.io.OutputStream destinationStream) throws java.io.UnsupportedEncodingException, java.io.IOException
java.io.UnsupportedEncodingException
java.io.IOException
public java.lang.String generateHTMLFromContent(java.lang.String content) throws java.io.UnsupportedEncodingException, java.io.IOException
java.io.UnsupportedEncodingException
java.io.IOException
public void generateHTMLFromContent(java.lang.String content, java.lang.String destinationFile) throws java.io.FileNotFoundException, java.io.UnsupportedEncodingException, java.io.IOException
java.io.FileNotFoundException
java.io.UnsupportedEncodingException
java.io.IOException
public void generateHTMLFromContent(java.lang.String content, java.io.File destinationFile) throws java.io.FileNotFoundException, java.io.UnsupportedEncodingException, java.io.IOException
java.io.FileNotFoundException
java.io.UnsupportedEncodingException
java.io.IOException
public static void main(java.lang.String[] args)