public final class ToHtml extends Object
| Modifier and Type | Method and Description |
|---|---|
static ToHtml |
create(InputStream in,
Appendable output)
Creates a new examples to HTML for the given workbook.
|
static ToHtml |
create(String path,
Appendable output)
Creates a new examples to HTML for the given workbook.
|
static ToHtml |
create(Workbook wb,
Appendable output)
Creates a new examples to HTML for the given workbook.
|
static void |
main(String[] args)
Run this class as a program
|
void |
print() |
void |
printPage() |
void |
printSheet(Sheet sheet) |
void |
printStyles() |
void |
setCompleteHTML(boolean completeHTML) |
protected int |
widthToPixels(double widthUnits)
Probably platform-specific, but appears to be a close approximation on some systems
|
public static ToHtml create(Workbook wb, Appendable output)
wb - The workbook.output - Where the HTML output will be written.public static ToHtml create(String path, Appendable output) throws IOException
.xlsx" an XSSFWorkbook will be used; otherwise
this will use an HSSFWorkbook.path - The file that has the workbook.output - Where the HTML output will be written.IOExceptionpublic static ToHtml create(InputStream in, Appendable output) throws IOException
XSSFWorkbook or not (so it should create an HSSFWorkbook).in - The input stream that has the workbook.output - Where the HTML output will be written.IOExceptionpublic static void main(String[] args) throws Exception
args - The command line arguments.Exception - Exception we don't recover from.public void setCompleteHTML(boolean completeHTML)
public void printPage()
throws IOException
IOExceptionpublic void print()
public void printStyles()
public void printSheet(Sheet sheet)
protected int widthToPixels(double widthUnits)
widthUnits - POI's native width unit (twips)