Workbook
Overview
Workbook is a class in Aspose.Cells FOSS for Java.
Inherits from: AutoCloseable.
Represents an Excel workbook.
Properties
| Name | Type | Access | Description |
|---|---|---|---|
worksheets | WorksheetCollection | Read | Returns the worksheets. |
settings | WorkbookSettings | Read | Returns the settings. |
properties | WorkbookProperties | Read | Returns the properties. |
documentProperties | DocumentProperties | Read | Returns the document properties. |
definedNames | DefinedNameCollection | Read | Returns the defined names. |
loadDiagnostics | LoadDiagnostics | Read | Returns the load diagnostics. |
Methods
| Signature | Description |
|---|---|
Workbook() | Initializes a new Workbook instance. |
Workbook(fileName: String) | Initializes a new Workbook instance. |
Workbook(stream: InputStream) | Initializes a new Workbook instance. |
Workbook(fileName: String, options: LoadOptions) | Initializes a new Workbook instance. |
Workbook(stream: InputStream, options: LoadOptions) | Initializes a new Workbook instance. |
getWorksheets() → WorksheetCollection | Returns the worksheets. |
getSettings() → WorkbookSettings | Returns the settings. |
getProperties() → WorkbookProperties | Returns the properties. |
getDocumentProperties() → DocumentProperties | Returns the document properties. |
getDefinedNames() → DefinedNameCollection | Returns the defined names. |
getLoadDiagnostics() → LoadDiagnostics | Returns the load diagnostics. |
save(fileName: String) | Saves the workbook to a file path (XLSX format). |
save(fileName: String, format: SaveFormat) | Saves the workbook to a file path with the given format. |
save(fileName: String, options: SaveOptions) | Saves the workbook to a file path with the given options. |
save(stream: OutputStream, format: SaveFormat) | Saves the workbook to a stream with the given format. |
save(stream: OutputStream, options: SaveOptions) | Saves the workbook to a stream with the given options. |
close() | Releases any resources associated with this instance. |