|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--com.actuate.util.Debug
|
+--com.f1j.util.Debug
|
+--com.f1j.util.ObjConst
|
+--com.f1j.util.Obj
|
+--com.f1j.util.SharedHelper
|
+--com.f1j.util.SharedObj
|
+--com.f1j.util.SharedHintedObj
|
+--com.f1j.mvc.ModelImpl
|
+--com.f1j.mvc.ModelImplEx
|
+--com.f1j.ss.BookImpl
This class implements the low level model for an e.Spreadsheet workbook. A workbook contains an array of sheets, as well as information which applies to the entire workbook.
| Field Summary | |
static short |
eClearAll
Clears data, formats, and objects. |
static short |
eClearContents
Clears cell data but leaves formatting intact. |
static short |
eClearDlg
Displays the Clear dialog box. |
static short |
eClearFormats
Clears formats only. |
static short |
eClearValues
Deprecated. Replaced by #eClearContents |
static short |
eColWidthUnitsNormal
Column width in characters. |
static short |
eColWidthUnitsTwips
Column width in twips. |
static short |
eCopyAll
Copies formats, values, and formulas. |
static short |
eCopyFormats
Copies formats. |
static short |
eCopyFormulas
Copies formulas and data. |
static short |
eCopyValues
Copies the values only; the result is a value without the formula that produced it. |
static short |
eEncryptionAuto
Deprecated. Replaced by DocumentEncryption.AUTO |
static short |
eEncryptionExcel97
Deprecated. Replaced by DocumentEncryption.EXCEL97 |
static short |
eEncryptionWeak
Deprecated. Replaced by DocumentEncryption.WEAK |
static short |
eFileActuate9
Deprecated. Replaced by DocumentType.ACTUATE_9_WORKBOOK |
static short |
eFileCurrentFormat
Deprecated. Replaced by DocumentType.CURRENT_FORMAT |
static short |
eFileESpreadsheet11
Deprecated. Replaced by DocumentType.ESPREADSHEET_11_WORKBOOK |
static short |
eFileExcel5
Deprecated. Replaced by DocumentType.EXCEL_5_WORKBOOK |
static short |
eFileExcel97
Deprecated. Replaced by DocumentType.EXCEL_97_WORKBOOK |
static short |
eFileExcel97And5
Excel 97-2003 and 5.x/95 format. |
static short |
eFileFormulaOne3
Deprecated. Replaced by DocumentType.FORMULA_ONE_3_WORKBOOK |
static short |
eFileFormulaOne6
Deprecated. Replaced by DocumentType.FORMULA_ONE_6_WORKBOOK |
static short |
eFileFormulaOne7
Deprecated. Replaced by DocumentType.FORMULA_ONE_7_WORKBOOK |
static short |
eFileTabbedText
Deprecated. Replaced by DocumentType.TABBED_TEXT |
static short |
eFileTabbedTextValuesOnly
Deprecated. Replaced by DocumentType.TABBED_TEXT_VALUES_ONLY |
static short |
eFileUnicodeText
Deprecated. Replaced by DocumentType.UNICODE_TEXT |
static short |
eFileUnicodeTextValuesOnly
Deprecated. Replaced by DocumentType.UNICODE_TEXT_VALUES_ONLY |
static short |
eFixupAppend
Append cells to a range during an insert. |
static short |
eFixupIgnoreAdjacentRanges
Ignore Adjacent Ranges |
static short |
eFixupPrepend
Prepend cells to a range during an insert. |
static short |
eOutlineCollapsed
Collapsed rows/columns in an outline. |
static short |
eOutlineExpanded
Expanded rows/columns in an outline. |
static short |
eOutlineTerminal
Terminals or leaf node rows/columns in an outline. |
static short |
eParamCurrency
Parameter Type - Currency |
static short |
eParamDate
Parameter Type - Date |
static short |
eParamDouble
Parameter Type - double |
static short |
eParametersFileActuate5
Deprecated. e.Spreadsheet 12 and up no longer write ROP files. |
static short |
eParametersFileActuate6
Deprecated. e.Spreadsheet 12 and up no longer write ROP files. |
static short |
eParametersFileActuate7
Deprecated. e.Spreadsheet 12 and up no longer write ROP files. |
static short |
eParametersFileActuate8
Deprecated. e.Spreadsheet 12 and up no longer write ROP files. |
static short |
eParamFormula
Parameter Type - Formula |
static short |
eParamInteger
Parameter Type - Integer |
static short |
eParamString
Parameter Type - String |
static short |
eQueryParamCurrency
Parameter Type - Currency |
static short |
eQueryParamDate
Parameter Type - Date |
static short |
eQueryParamDouble
Parameter Type - double |
static short |
eQueryParamFormula
Parameter Type - Formula |
static short |
eQueryParamInteger
Parameter Type - Integer |
static short |
eQueryParamString
Parameter Type - String |
static short |
eSheetHidden
Indicates the sheet is hidden. |
static short |
eSheetShown
Indicates the sheet is not hidden. |
static short |
eSheetTypeChart
Chartsheet sheet type. |
static short |
eSheetTypeSheet
Worksheet sheet type. |
static short |
eSheetVeryHidden
Indicates the sheet is hidden and the user is not allowed to unhide it via the Workbook Designer. |
static short |
eShiftColumns
Columns in which the range resides are deleted. |
static short |
eShiftHorizontal
Cells to the right of the range are shifted left to fill the vacated space. |
static short |
eShiftRows
Rows in which the range resides are deleted. |
static short |
eShiftVertical
Cells below the range are shifted up to fill the vacated space. |
static short |
eShowAutomatic
Selections or scroll bars are displayed if book or control is active. |
static short |
eShowOff
Selections or scrollbars are hidden. |
static short |
eShowOn
Selections or scrollbars are displayed. |
static short |
eTabsBottom
Tabs appear at the bottom of worksheets. |
static short |
eTabsOff
Tabs do not appear on worksheets. |
static short |
eTabsTop
Tabs appear at the top of worksheets. |
static short |
eTypeEmpty
Indicates an empty cell. |
static short |
eTypeError
Indicates the cell contains an error. |
static short |
eTypeLogical
Indicates a logical cell. |
static short |
eTypeNumber
Indicates a number cell. |
static short |
eTypeText
Indicates a text cell. |
static int |
kAllowDefault
Sheet protection allows default standard operations. |
static int |
kAllowDeleteColumns
Sheet protection allows Delete columns. |
static int |
kAllowDeleteRows
Sheet protection allows Delete rows. |
static int |
kAllowEditObjects
Sheet protection allows Edit objects. |
static int |
kAllowFormatCells
Sheet protection allows Format cells. |
static int |
kAllowFormatColumns
Sheet protection allows Format columns. |
static int |
kAllowFormatRows
Sheet protection allows Format rows. |
static int |
kAllowInsertColumns
Sheet protection allows Insert columns. |
static int |
kAllowInsertHyperlinks
Sheet protection allows Insert hyperlinks. |
static int |
kAllowInsertRows
Sheet protection allows Insert rows. |
static int |
kAllowNone
Sheet protection allows nothing. |
static int |
kAllowSelectLocked
Sheet protection allows Select locked cells. |
static int |
kAllowSelectUnlocked
Sheet protection allows Select unlocked cells. |
static int |
kAllowSort
Sheet protection allows Sort. |
static int |
kAllowUseAutoFilter
Sheet protection allows Use AutoFilter. |
static int |
kAllowUsePivotRanges
Sheet protection allows Use PivotRange reports. |
static int |
kCodePageDefaultANSI
default ANSI (language-specific) code page. |
static int |
kCodePageUnicodeBE
Unicode Big Endian (UTF-16) code page. |
static int |
kCodePageUnicodeLE
Unicode Little Endian (UTF-16) code page. |
static int |
kCodePageUTF8
UTF-8 code page. |
static int |
kContentsChanged
Cell contents were changed in an entry method. |
static int |
kFontChanged
Font was changed in an entry method. |
static int |
kFormatChanged
Format was changed in an entry method. |
static int |
kMaxCellText
The maximum length of text in a cell. |
static int |
kMaxCol
The maximum column number. |
static int |
kMaxCols
The maximum number of columns. |
static int |
kMaxPaletteEntry
The maximum number of palatte entries. |
static int |
kMaxRow
The maximum row number. |
static int |
kMaxRows
The maximum number of rows. |
static int |
kMaxSheet
The maximum sheet number. |
static int |
kMaxSheets
The maximum number of sheets. |
static int |
kProtectStructure
Workbook structure is protected. |
| Constructor Summary | |
BookImpl()
Constructs a new uninitialized workbook. |
|
BookImpl(Group group)
Constructs a new uninitialized workbook and makes it part of the specified group. |
|
| Method Summary | |
void |
checkRecalc()
Recalculates the workbook, if needed. |
void |
copyAll(Book srcBook)
Copies the contents of one workbook to another workbook. |
void |
copySheet(int insertAt,
BookView bookView)
Creates copies of all sheets selected in the specified view. |
void |
copySheet(int insertAt,
Range rangeAPI)
Creates copies of the specified sheets. |
DataBase |
createDatabase()
Creates a new Database object. |
void |
deleteDefinedName(java.lang.String name)
Deletes the specified user-defined name. |
void |
deleteSheet(BookView bookView)
Deletes the sheets selected in the specified view. |
void |
deleteSheet(Range rangeAPI)
Deletes the specified sheets. |
void |
deleteSheets(int nDeleteAt,
int nSheets)
Deletes one or more worksheets from a workbook The names displayed on the sheet tabs are not affected by the deletions; however, the worksheet index is adjusted. |
Book |
findBook(java.lang.String bookName)
Attempts to find a workbook with the specified name in the same group as this workbook. |
void |
forceRecalc()
Marks all formulas in the workbook as needing to be recalculated. |
java.lang.String |
formatRCNr(int row,
int col,
boolean bAbsRow,
boolean bAbsCol)
Formats a row and column number as text. |
void |
gc(boolean collectFormats,
boolean collectFormulas)
Performs garbage collection on formatting and/or formula information associated with a workbook. |
CellFormat |
getCellFormat(int sheet1,
int row1,
int col1,
int sheet2,
int row2,
int col2)
Returns the format of the specified range of cells in the specified range of sheets. |
java.lang.String |
getCodeName()
Returns the VBA object name assigned to this workbook. |
short |
getColWidthUnits()
Returns whether column widths are stored and displayed in twips or in character units. |
DataSet |
getDefaultDataSet()
Returns the default DataSet for this book. |
java.lang.String |
getDefinedName(java.lang.String name,
int row,
int col)
Returns the definition associated with a defined name given the offset provided by the row and column parameters. |
int |
getDefinedNameCount()
Returns the number of defined names in a view. |
Document |
getDocument()
Returns the Document object associated with this book. |
java.lang.String |
getGroupName()
Returns the Group name for this Book. |
java.lang.String |
getHyperlinkBase()
Returns the hyperlink base string used for relative hyperlinks. |
int |
getIterationMax()
Returns the maximum number of calculation iterations. |
double |
getIterationMaxChange()
Returns the maximum iteration change value. |
long |
getModifiedCount()
Returns the modified count of this workbook. |
java.lang.String |
getName()
Returns the name assigned to this workbook. |
PivotGroup |
getPivotGroup()
Returns a reference to the PivotRange group. |
int |
getProtectionFlags()
Returns a set of flags indicating which actions are protected on this workbook when protection is enabled. |
ReadResults |
getReadResults()
Deprecated. Replaced by Document.getDocumentSaveOptions(), Document.getDocumentType() |
ReportFunctionsGroup |
getReportFunctionsGroup()
Returns a reference to the ReportFunctionsGroup. |
Sheet |
getSheet(int sheet)
Returns the Sheet at the specified index. |
int |
getSheetCount()
Returns the number of worksheets in this workbook. |
int |
getVersion()
Returns the version of the component. |
java.lang.String |
getVersionString()
Returns the version of the component in a string. |
boolean |
hasPivotGroup()
Returns true if the book has a PivotRange group. |
boolean |
hasReportFunctionsGroup()
Returns true if the book has a ReportFunctionsGroup. |
void |
initBook()
Initilaizes a workbook to a default, empty state. |
void |
insertSheet(BookView bookView)
Inserts one or more sheets before the active sheet of the specified view. |
void |
insertSheets(int nInsertAt,
int nSheets)
Inserts one or more worksheets at the specified location. |
boolean |
isAutoRecalc()
Returns whether or not automatic recalc is on. |
boolean |
isColWidthInTwips()
Returns whether column widths are stored in twips for this workbook. |
boolean |
isIterationEnabled()
Returns true if iteration is enabled. |
boolean |
isPasswordProtected()
Returns true if protection is enabled with a password for this workbook. |
boolean |
isPrecisionAsDisplayed()
Returns true if all cell values are rounded to the displayed
precision. |
boolean |
isProhibited(int protectionFlags)
Returns true if the workbook is protected and the
workbook's current protection settings include the specified flags. |
boolean |
isProtected()
Returns true if protection is enabled for this workbook. |
void |
moveSheet(int insertAt,
BookView bookView)
Moves all sheets selected in the specified view, to a specified location. |
void |
moveSheet(int insertAt,
Range rangeAPI)
Moves the specified sheets to a specified location. |
short |
read(byte[] blob)
Deprecated. Replaced by Document.Document(com.f1j.util.Group, byte[], DocumentOpenCallback) |
ReadResults |
read(byte[] blob,
com.f1j.ss.ReadParams rp)
Deprecated. Replaced by Document.Document(com.f1j.util.Group, byte[], DocumentOpenCallback) |
short |
read(java.io.InputStream inputStream)
Deprecated. Replaced by Document.Document(com.f1j.util.Group, java.io.InputStream, DocumentOpenCallback) |
ReadResults |
read(java.io.InputStream inputStream,
com.f1j.ss.ReadParams rp)
Deprecated. Replaced by Document.Document(com.f1j.util.Group, java.io.InputStream, DocumentOpenCallback) |
short |
read(java.io.InputStream inputStream,
short eCodePage)
Deprecated. Replaced by Document.Document(com.f1j.util.Group, java.io.InputStream, DocumentOpenCallback) |
short |
read(java.lang.String fileName)
Deprecated. Replaced by Document.Document(com.f1j.util.Group, java.io.File, boolean, DocumentOpenCallback) |
ReadResults |
read(java.lang.String fileName,
com.f1j.ss.ReadParams rp)
Deprecated. Replaced by Document.Document(com.f1j.util.Group, java.io.File, boolean, DocumentOpenCallback) |
short |
readFromBlob(byte[] blob)
Deprecated. Replaced by Document.Document(com.f1j.util.Group, byte[], DocumentOpenCallback) |
ReadResults |
readFromBlob(byte[] blob,
com.f1j.ss.ReadParams rp)
Deprecated. Replaced by Document.Document(com.f1j.util.Group, byte[], DocumentOpenCallback) |
void |
recalc()
Recalculates this workbook. |
void |
setAutoRecalc(boolean autoRecalc)
Sets the flag that determines whether or not automatic recalc is on. |
void |
setCodeName(java.lang.String codeName)
Assigns a VBA object name to this workbook. |
void |
setDefaultDataSet(DataSet dataSet)
Sets the default DataSet for this book. |
void |
setDefinedName(java.lang.String name,
java.lang.String formula,
int row,
int col)
Sets the formula associated with a defined name, in US English. |
void |
setDefinedName(java.lang.String name,
java.lang.String formula,
int row,
int col,
boolean param,
boolean strip,
short type)
Sets the formula associated with a defined name, in US English. |
void |
setDefinedName(java.lang.String name,
java.lang.String formula,
Sheet sheet,
int row,
int col)
Sets the formula associated with a defined name, in US English. |
void |
setDefinedName(java.lang.String name,
java.lang.String formula,
Sheet sheet,
int row,
int col,
boolean param,
boolean strip,
short type)
Sets the formula associated with a defined name, in US English. |
void |
setGroupName(java.lang.String group)
Sets the group name for this workbook. |
void |
setHyperlinkBase(java.lang.String s)
Sets the hyperlink base string - use null to turn off Book. |
void |
setIterationEnabled(boolean iterationEnabled)
Sets whether iteration is enabled. |
void |
setIterationMax(int iterationMax)
Sets the maximum number of iterations. |
void |
setIterationMaxChange(double iterationMaxChange)
Sets the maximum iteration change value. |
void |
setName(java.lang.String name)
Sets the name assigned to this workbook. |
void |
setNumSheets(int sheets)
Sets the number of worksheets in this workbook. |
void |
setPrecisionAsDisplayed(boolean precisionAsDisplayed)
Determines whether cell values are stored as entered or as displayed. |
void |
setProtection(boolean enableProtection,
java.lang.String password,
int flags)
Sets whether protection is enabled for this workbook. |
boolean |
write(Sheet sheet,
java.io.OutputStream stream,
short eFileType)
Deprecated. Replaced by Document.fileSaveCopyAs(java.io.OutputStream, DocumentType, DocumentSaveCallback) |
boolean |
write(Sheet sheet,
java.io.OutputStream stream,
short eFileType,
short eCodePage)
Deprecated. Replaced by Document.fileSaveCopyAs(java.io.OutputStream, DocumentType, DocumentSaveCallback) |
boolean |
write(Sheet sheet,
java.io.OutputStream stream,
com.f1j.ss.WriteParams wp)
Deprecated. Replaced by Document.fileSaveCopyAs(java.io.OutputStream, DocumentType, DocumentSaveCallback) |
byte[] |
write(Sheet sheet,
short eFileType)
Deprecated. Replaced by Document.fileSaveCopyAsByteArray(DocumentType, DocumentSaveCallback) |
boolean |
write(Sheet sheet,
java.lang.String pathName,
short eFileType)
Deprecated. Replaced by Document.fileSaveCopyAs(java.io.File, DocumentType, DocumentSaveCallback) |
boolean |
write(Sheet sheet,
java.lang.String pathName,
com.f1j.ss.WriteParams wp)
Deprecated. Replaced by Document.fileSaveCopyAs(java.io.File, DocumentType, DocumentSaveCallback) |
byte[] |
write(Sheet sheet,
com.f1j.ss.WriteParams wp)
Deprecated. Replaced by Document.fileSaveCopyAsByteArray(DocumentType, DocumentSaveCallback) |
byte[] |
writeToBlob()
Deprecated. Replaced by Document.fileSaveCopyAsByteArray(DocumentType, DocumentSaveCallback) |
byte[] |
writeToBlob(Sheet sheet,
com.f1j.ss.WriteParams wp)
Deprecated. Replaced by Document.fileSaveCopyAsByteArray(DocumentType, DocumentSaveCallback) |
boolean |
writeURL(Sheet sheet,
java.net.URL url,
com.f1j.ss.WriteParams wp)
Deprecated. This method still works at this time, but in a future release e.Spreadsheet will no longer write to a URL. |
| Constructor Detail |
public BookImpl()
Book.initBook(),
Book.read(byte[]),
Book.readFromBlob(byte[])public BookImpl(Group group)
group - the Group object to make this
BookImpl part of. If the group parameter is
null, a new Group is created.Book.initBook(),
Book.read(byte[]),
Book.readFromBlob(byte[])| Method Detail |
public Document getDocument()
Document object associated with this book.public void checkRecalc()
forceRecalc(),
isAutoRecalc(),
recalc(),
setAutoRecalc(boolean)
public void copyAll(Book srcBook)
throws F1Exception
srcBook - a handle to the source workbook.public DataBase createDatabase()
DataBase
public void deleteDefinedName(java.lang.String name)
throws F1Exception
name - identifies the user-defined name to delete.getDefinedName(java.lang.String, int, int),
setDefinedName(java.lang.String, java.lang.String, int, int, boolean, boolean, short)
public void deleteSheets(int nDeleteAt,
int nSheets)
throws F1Exception
sheet - specifies the sheet index number of the first worksheet to
delete. Do not confuse the sheet index number with the sheet name on the
sheet tab.sheets - specifies how many sheets to delete, beginning with the
worksheet specified by the sheet parameter.insertSheets(int, int)
public void deleteSheet(BookView bookView)
throws SelectionException,
InvalidArgumentException,
AccessDeniedException
Deletes the sheets selected in the specified view.
bookView - The view whose active sheet is the insertion point for the new sheets.insertSheet(BookView),
deleteSheet(Range),
BookModel.deleteSheet()
public void deleteSheet(Range rangeAPI)
throws SelectionException,
InvalidArgumentException,
AccessDeniedException
Deletes the specified sheets.
range - A range object specifying the sheets to be deleted.range contains all visible sheets in the workbook.insertSheet(BookView),
deleteSheet(BookView),
BookModel.deleteSheet(Range)
public void moveSheet(int insertAt,
Range rangeAPI)
throws InvalidArgumentException
nInsertAt - The location to which to move the sheets.range - A range object specifying the sheets to be moved.insertAt is not a valid sheet index.moveSheet(int, BookView),
copySheet(int, Range),
BookModel.moveSheet(int, Range)
public void moveSheet(int insertAt,
BookView bookView)
throws InvalidArgumentException
insertAt - The location to which to move the sheets.bookView - The view whose selection is to be moved.insertAt is not a valid sheet index.moveSheet(int, Range),
copySheet(int, BookView),
BookModel.moveSheet(int)public Book findBook(java.lang.String bookName)
bookName - the name of the workbook to find.Book object. Returns null if the specified Book
object is not found.public void forceRecalc()
checkRecalc(),
isAutoRecalc(),
recalc(),
setAutoRecalc(boolean)
public void gc(boolean collectFormats,
boolean collectFormulas)
As a general rule, resources associated with formatting are garbage collected only when a workbook is saved, whereas formula information is normally garbage collected by a background thread after recalculation is complete, as well as when a workbook is saved. This normal operation has proven to be more than adequate for normal interactive use.
In some circumstances it might be necessary to call this method from time to time to prevent e.Spreadsheet from keeping too much of this stale information around.
If you are using
com.f1j.ss.Book directly (as you might in a
server environment), there is no background thread cleaning up the formula
information. If your application is making many dynamic changes of a
non-repetitive nature to formulas or defined names, you will probably need
to call Book.gc(false, true) from time to time to keep Formula
One from leaking memory. Note that, because all workbooks within a group
share one set of formula information, this operation garbage collects formula
information for all workbooks in a group.If your application never writes out a workbook to a workbook format (Excel or e.Spreadsheet), and is making many non-repetitive, dynamic changes to workbook formatting (cell formats, fonts, validation rules), you will probably need to call
Book.gc(true, false) from time to time to
keep e.Spreadsheet from leaking memory.Saved workbook files never contain stale formatting or formula information.
Initializing a workbook or reading a new workbook into a workbook always forces garbage collection to occur.
collectFormats - boolean. true to do garbage collection on
the formatting information.collectFormulas - boolean. true to do garbage collection on
the formula information for all workbooks in the same group as the specified
workbook.
public CellFormat getCellFormat(int sheet1,
int row1,
int col1,
int sheet2,
int row2,
int col2)
throws F1Exception
sheet1 - the beginning sheet.row1 - the first row in the range.col1 - the first column in the range.sheet2 - the ending sheet.row2 - the ending row in the range.col2 - the ending column in the range.
Rows are indexed from top to bottom beginning with 0. Sheets and columns are
indexed from left to right beginning with 0.public short getColWidthUnits()
eColWidthUnitsNormal = 0
eColWidthUnitsTwips = 1BookModel.setColWidthUnits(short)public DataSet getDefaultDataSet()
setDefaultDataSet(com.f1j.data.DataSet),
DataSet
public void setDefaultDataSet(DataSet dataSet)
throws InvalidArgumentException
dataSet - The DataSet that should be used as the default for this book.getDefaultDataSet(),
DataSet
public java.lang.String getDefinedName(java.lang.String name,
int row,
int col)
throws F1Exception
name - the defined name.row - a relative defined name definition will be adjusted so it
is relative to this row.col - a relative defined name definition will be adjusted so it
is relative to this column.deleteDefinedName(java.lang.String),
setDefinedName(java.lang.String, java.lang.String, int, int, boolean, boolean, short)public PivotGroup getPivotGroup()
public ReportFunctionsGroup getReportFunctionsGroup()
public java.lang.String getGroupName()
setGroupName(java.lang.String)public int getIterationMax()
setIterationEnabled(boolean),
setIterationMax(int)public double getIterationMaxChange()
setIterationMaxChange(double)public long getModifiedCount()
getModifiedCount() method was called.getModifiedCount(),
ModifiedEvent,
ModifiedListener,
ReadResults.isModified()public java.lang.String getName()
setName(java.lang.String),
getCodeName()public java.lang.String getCodeName()
setCodeName(java.lang.String),
getName()public ReadResults getReadResults()
Document.getDocumentSaveOptions(), Document.getDocumentType()ReadResults
object returned contains the file properties associated with the most recent
read and/or write operations performed on this workbook.
If no read or write operation has ever been performed on this workbook, a valid object with default settings is returned.
read(byte[]),
write(com.f1j.ss.Sheet, short),
ReadResultspublic Sheet getSheet(int sheet)
sheet - the index number of the sheet to return; 0-based.getSheetCount(),
BookModel.setSheet(int)public int getSheetCount()
setNumSheets(int)public int getVersion()
getVersionString()public java.lang.String getVersionString()
getVersion()public boolean hasPivotGroup()
Returns true if the book has a PivotRange group.
In applications where the presence of PivotRange group without actual PivotRanges is considered undesirable because of memory footprint or file size concerns, this method should be called to see if a group already exist in the book. This way the application can avoid a call to the getPivotGroup method, which would automatically create a PivotRange group.
true/falsegetPivotGroup()public boolean hasReportFunctionsGroup()
Returns true if the book has a ReportFunctionsGroup.
In applications where the presence of ReportFunctionsGroup without actual Report Functions is considered undesirable because of memory footprint or file size concerns, this method should be called to see if a group already exist in the book. This way the application can avoid a call to the getReportFunctionsGroup method, which would automatically create a ReportFunctionsGroup. \ *
true/falsegetReportFunctionsGroup()public void initBook()
write(com.f1j.ss.Sheet, short)public boolean isAutoRecalc()
true = automatic recalc is on.forceRecalc(),
checkRecalc(),
recalc(),
setAutoRecalc(boolean)public boolean isIterationEnabled()
true if iteration is enabled.
Iteration can be used to resolve circular references. e.Spreadsheet calculates
until it has iterated the number of times specified by the maximum number of
iterations set in the setIterationMax method or until
all cells change by less than the amount specified as the maximum iteration
change value in the setIterationMaxChange method.
Iteration is enabled by calling the setIterationEnabled method.true = iteration is enabled.setIterationEnabled(boolean)public boolean isPrecisionAsDisplayed()
true if all cell values are rounded to the displayed
precision.
If true, the value in each cell is rounded to the precision
displayed in the cell. If false, the value in each cell is
stored as entered or calculated.true = cell values are rounded.setPrecisionAsDisplayed(boolean)
public short read(byte[] blob)
throws F1Exception
Document.Document(com.f1j.util.Group, byte[], DocumentOpenCallback)blob - a reference to a byte array.read(byte[]),
write(com.f1j.ss.Sheet, short),
writeToBlob()
public ReadResults read(byte[] blob,
com.f1j.ss.ReadParams rp)
throws F1Exception
Document.Document(com.f1j.util.Group, byte[], DocumentOpenCallback)blob - reference to a byte array.rp - parameters for this read operation.ReadParams,
ReadResults,
read(byte[]),
write(com.f1j.ss.Sheet, short),
writeToBlob()
public short read(java.io.InputStream inputStream)
throws java.io.IOException,
F1Exception
Document.Document(com.f1j.util.Group, java.io.InputStream, DocumentOpenCallback)inputStream - the
input stream to read from.readFromBlob(byte[]),
write(com.f1j.ss.Sheet, short)
public short read(java.io.InputStream inputStream,
short eCodePage)
throws java.io.IOException,
F1Exception