|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Object | +--com.jrefinery.workbook.JWorkbook
Represents a workbook so that it can be exported to (for now) the Gnumeric XML file format. This class can be used to export data to spreadsheets from Java. The file format can, of course, be read directly into Gnumeric. But there is also a plan to write an importer for Excel (unless there already is one).
Note that this workbook does not have a calculation engine, and I have no plans to add one at this point (too much work!). Maybe one day it will happen, it would be nice...
| Field Summary | |
protected int |
geometry_height
The height of the workbook when displayed in Gnumeric. |
protected int |
geometry_width
The width of the workbook when displayed in Gnumeric. |
static java.lang.String |
INDENT
Standard indentation in the output file. |
protected java.lang.String |
name
The workbook name. |
protected java.util.ArrayList |
names
Names defined in the workbook - not currently supported. |
protected boolean |
show_horizontal_scrollbar
Visibility of the horizontal scroll bar. |
protected boolean |
show_notebook_tabs
Visibility of the notebook tabs. |
protected boolean |
show_vertical_scrollbar
Visibility of the vertical scroll bar. |
protected Summary |
summary
A summary of the workbook. |
static java.lang.String |
VERSION
Version identification. |
protected java.util.ArrayList |
worksheets
The worksheets contained in this workbook. |
| Constructor Summary | |
JWorkbook()
Default constructor: creates a new empty workbook. |
|
JWorkbook(java.lang.String name,
int sheets)
Standard constructor. |
|
| Method Summary | |
Worksheet |
add(java.lang.String name)
Adds a worksheet with the specified name. |
static void |
main(java.lang.String[] args)
Test program to demonstrate the idea "in principle". |
void |
saveAs(java.lang.String filename)
Saves the workbook in Gnumeric XML format. |
void |
setAuthor(java.lang.String name)
Sets the author attribute. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String VERSION
public static final java.lang.String INDENT
protected java.lang.String name
protected boolean show_horizontal_scrollbar
protected boolean show_vertical_scrollbar
protected boolean show_notebook_tabs
protected Summary summary
protected java.util.ArrayList names
protected int geometry_width
protected int geometry_height
protected java.util.ArrayList worksheets
| Constructor Detail |
public JWorkbook()
public JWorkbook(java.lang.String name,
int sheets)
name - The workbook name.sheets - The number of worksheets in the workbook (initially).| Method Detail |
public Worksheet add(java.lang.String name)
name - The worksheet name.public void setAuthor(java.lang.String name)
name - The name of the author.public void saveAs(java.lang.String filename)
filename - The name of the file.public static void main(java.lang.String[] args)
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||