alexa
menu

MAUI

  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Search Results for

    Show / Hide Table of Contents

    Class SSTDictionary

    Dictionary is used for grouping strings used by Excel in order to prevent doubling of data. Dictionary stores information as key string and value.

    Inheritance
    object
    SSTDictionary
    Implements
    IParseable
    IDisposable
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Syncfusion.XlsIO.Implementation
    Assembly: Syncfusion.XlsIO.NET.dll
    Syntax
    public class SSTDictionary : IParseable, IDisposable

    Constructors

    SSTDictionary(WorkbookImpl)

    Default constructor. Reserves space for strings.

    Declaration
    public SSTDictionary(WorkbookImpl book)
    Parameters
    Type Name Description
    WorkbookImpl book

    Fields

    DEF_EMPTY_STRING_INDEX

    Index of the empty string.

    Declaration
    public const int DEF_EMPTY_STRING_INDEX = -1
    Field Value
    Type
    int

    Properties

    ActiveCount

    Returns number of strings without removed items. Read-only.

    Declaration
    public int ActiveCount { get; }
    Property Value
    Type
    int

    Count

    Gets quantity of unique strings.

    Declaration
    public int Count { get; }
    Property Value
    Type
    int

    this[TextWithFormat]

    Gets references count to specified string.

    Declaration
    public int this[TextWithFormat key] { get; }
    Parameters
    Type Name Description
    TextWithFormat key
    Property Value
    Type
    int

    this[int]

    Gets text with format.

    Declaration
    public TextWithFormat this[int index] { get; }
    Parameters
    Type Name Description
    int index
    Property Value
    Type
    TextWithFormat

    Keys

    Gets list of strings.

    Declaration
    public object[] Keys { get; }
    Property Value
    Type
    object[]

    OriginalSST

    Gets / sets original SSTRecord.

    Declaration
    [CLSCompliant(false)]
    public SSTRecord OriginalSST { get; set; }
    Property Value
    Type
    SSTRecord

    UseHashForSearching

    Declaration
    public bool UseHashForSearching { get; set; }
    Property Value
    Type
    bool

    Workbook

    Returns parent workbook. Read-only.

    Declaration
    public WorkbookImpl Workbook { get; }
    Property Value
    Type
    WorkbookImpl

    Methods

    AddCopy(int, SSTDictionary, Dictionary<int, int>)

    Adds copy of the string from another collection.

    Declaration
    public int AddCopy(int index, SSTDictionary sourceSST, Dictionary<int, int> dicFontIndexes)
    Parameters
    Type Name Description
    int index

    Index of the string to add.

    SSTDictionary sourceSST

    Source string table.

    Dictionary<int, int> dicFontIndexes

    Dictionary with font indexes.

    Returns
    Type Description
    int

    Index of the added string.

    AddIncrease(int)

    Adds string into dictionary. If the string exists in dictionary, add reference count. Method can influence on SST Indexes.

    Declaration
    public void AddIncrease(int index)
    Parameters
    Type Name Description
    int index

    Index to the string.

    AddIncrease(object)

    Adds string into dictionary. If the string exists in dictionary, add reference count. Method can influence on SST Indexes.

    Declaration
    public int AddIncrease(object key)
    Parameters
    Type Name Description
    object key

    String to add

    Returns
    Type Description
    int

    Index of the added string.

    AddIncrease(object, bool)

    Adds string into dictionary. If the string exists in dictionary, add reference count. Method can influence on SST Indexes.

    Declaration
    public int AddIncrease(object key, bool bIncrease)
    Parameters
    Type Name Description
    object key

    String to add

    bool bIncrease

    Reference count for new entries.

    Returns
    Type Description
    int

    Index of the added string.

    Clear()

    Clears the list.

    Declaration
    public void Clear()

    Clone(WorkbookImpl)

    Creates copy of the current instance.

    Declaration
    public object Clone(WorkbookImpl book)
    Parameters
    Type Name Description
    WorkbookImpl book
    Returns
    Type Description
    object

    Copy of the current instance.

    Contains(object)

    Method checks if the dictionary contains the specified string.

    Declaration
    public bool Contains(object key)
    Parameters
    Type Name Description
    object key

    String which must be checked.

    Returns
    Type Description
    bool

    True - string exists in dictionary, otherwise False.

    DecreaseOnly(int)

    Method decreases reference count of string without removing it.

    Declaration
    public void DecreaseOnly(int index)
    Parameters
    Type Name Description
    int index

    Index of the string to decrease reference.

    Dispose()

    Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

    Declaration
    public void Dispose()

    ~SSTDictionary()

    Declaration
    protected ~SSTDictionary()

    GetSSTContentByIndex(int)

    Returns SST content.

    Declaration
    public object GetSSTContentByIndex(int index)
    Parameters
    Type Name Description
    int index

    Index of the target string.

    Returns
    Type Description
    object

    SST content object.

    GetStringByIndex(int)

    Returns RTF string by its index in the dictionary.

    Declaration
    public TextWithFormat GetStringByIndex(int index)
    Parameters
    Type Name Description
    int index

    Index of the target string.

    Returns
    Type Description
    TextWithFormat

    RTF string.

    GetStringCount(int)

    Returns number of strings in the dictionary.

    Declaration
    public int GetStringCount(int index)
    Parameters
    Type Name Description
    int index

    Index of the target string.

    Returns
    Type
    int

    GetStringIndexes(string)

    Searches for all strings with specified text.

    Declaration
    public Dictionary<int, object> GetStringIndexes(string value)
    Parameters
    Type Name Description
    string value

    String to search.

    Returns
    Type Description
    Dictionary<int, object>

    Dictionary, key - string index, value - null.

    Parse()

    Here we have to parse our SST record

    Declaration
    public void Parse()

    RemoveDecrease(int)

    Remove reference of string. When reference count reaches zero, string will be removed from dictionary. Method can influence the SST indexes.

    Declaration
    public void RemoveDecrease(int iIndex)
    Parameters
    Type Name Description
    int iIndex

    String index to remove.

    RemoveDecrease(object)

    Remove reference of string. When reference count reaches zero, string will be removed from dictionary. Method can influence the SST indexes.

    Declaration
    public void RemoveDecrease(object key)
    Parameters
    Type Name Description
    object key

    String whose reference must be removed.

    Exceptions
    Type Condition
    ArgumentException

    When SST table does not contain the specified string.

    RemoveUnnecessaryStrings()

    This methods looks through all row storages to find out used strings. And removes all unnecessary strings after that.

    Declaration
    public void RemoveUnnecessaryStrings()

    Serialize(OffsetArrayList)

    Serialize dictionary.

    Declaration
    [CLSCompliant(false)]
    public void Serialize(OffsetArrayList records)
    Parameters
    Type Name Description
    OffsetArrayList records

    Records where writes serialized data.

    StartWith(string)

    Searches for all strings that starts with specified string.

    Declaration
    public List<int> StartWith(string strStart)
    Parameters
    Type Name Description
    string strStart

    String prefix to search.

    Returns
    Type Description
    List<int>

    List with all string indexes that starts with specified string, in ascending order.

    UpdateRefCounts()

    Updates internal array that stores reference count.

    Declaration
    public void UpdateRefCounts()

    Implements

    IParseable
    IDisposable
    In this article
    Back to top Generated by DocFX
    Copyright © 2001 - 2026 Syncfusion Inc. All Rights Reserved