OfficeIMO

API Reference

Class

SharedStringPlanner

Namespace OfficeIMO.Excel

Planner for SharedStrings to avoid DOM mutations during parallel compute. Collects distinct strings concurrently, applies them under document lock, and fixes up prepared cell values to reference shared string indices.

Inheritance

  • Object
  • SharedStringPlanner

Methods

ApplyAndFixup(System.ValueTuple{System.Int32,System.Int32,DocumentFormat.OpenXml.Spreadsheet.CellValue,DocumentFormat.OpenXml.EnumValue{DocumentFormat.OpenXml.Spreadsheet.CellValues}}[] prepared, OfficeIMO.Excel.ExcelDocument doc) #

Applies planner to document and fixes all prepared cells. Must be called inside serialized apply stage.

Parameters

prepared System.ValueTuple{System.Int32,System.Int32,DocumentFormat.OpenXml.Spreadsheet.CellValue,DocumentFormat.OpenXml.EnumValue{DocumentFormat.OpenXml.Spreadsheet.CellValues}}[] required
doc OfficeIMO.Excel.ExcelDocument required
ApplyTo(OfficeIMO.Excel.ExcelDocument doc) #

Apply collected strings to the document's SharedStringTable and build final index mapping. Must be called inside a serialized apply stage (under document write lock).

Parameters

doc OfficeIMO.Excel.ExcelDocument required
Fixup(System.ValueTuple{System.Int32,System.Int32,DocumentFormat.OpenXml.Spreadsheet.CellValue,DocumentFormat.OpenXml.EnumValue{DocumentFormat.OpenXml.Spreadsheet.CellValues}}@ prepared) #

Fixes a prepared cell tuple in-place, replacing SharedString text with its index.

Parameters

prepared System.ValueTuple{System.Int32,System.Int32,DocumentFormat.OpenXml.Spreadsheet.CellValue,DocumentFormat.OpenXml.EnumValue{DocumentFormat.OpenXml.Spreadsheet.CellValues}}@ required