public final class MemorySetting
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static int |
FILE_CACHE
Memory performance preferable and using file instead of memory
to maintain the cells data.
|
static int |
MEMORY_PREFERENCE
Memory performance preferable.
|
static int |
NORMAL
Default mode for cells model.
|
public static final int NORMAL
Remarks
This mode is applied for all versions.public static final int MEMORY_PREFERENCE
Remarks
With this mode the cells data will be maintained in compact format to decrease the memory cost. On other hand, the compact data also may cause higher time cost, especially when updating the cells data, or accessing it randomly.public static final int FILE_CACHE
Remarks
With this mode the cells data will be maintained in compact format and the major part of the data will be maintained in temporary file instead of memory. So when comparing withMEMORY_PREFERENCE mode,
this mode may decrease the memory cost more, but the IO operations for accessing
cells data also will cause higher time cost.
| Some notable limits and recommended operations when using this mode: |
|---|
When this mode is used for any worksheet in one workbook, Workbook.dispose()
should be called at the end of work to release all resources such as the temporary files.
|
| Randomly accessing cells will give poor performance because data needs to be read randomly and repeatedly(so the pointer in the file will be changed accordingly and IO operations will be required repeatedly). If possible, please always access the data sequentially(row by row). |
| When the data of one row/cell be changed, data of other cells/rows may also be influenced(such as the data be shifted/moved to other places to allocated enough spaces for the changed data). So every change of every data requires synchronization of other existing objects(such as Row or Cell object). So, to get better performance, please do not maintain multiple Rows/Cells at the same time. Processing them one by one will reduce the data synchronization for them so the performance can be improved. |
See Also:
Aspose.Cells Documentation - the home page for the Aspose.Cells Product Documentation.
Aspose.Cells Support Forum - our preferred method of support.
We guarantee a prompt response to any inquiry!
© Aspose Pty Ltd 2003-2025. All Rights Reserved.