Aspose.Cells 8.0.1中的公共API变更

向Cells类添加了MemorySetting属性

Cells类已经公开了setMemorySetting和getMemorySetting方法,用于优化单元格数据的内存使用,并因此减少总体内存开销。下面的示例展示了如何以优化模式将大量数据写入工作表。

Java

 //Instantiate a new Workbook

Workbook book = new Workbook();

//Set the memory preferences

book.getSettings().setMemorySetting(MemorySetting.MEMORY_PREFERENCE);

//To change the memory setting of existing sheets, please change memory setting for them manually:

Cells cells = book.getWorksheets().get(0).getCells();

cells.setMemorySetting(MemorySetting.MEMORY_PREFERENCE);

//Input large dataset into the cells of the worksheet.

//Your code goes here