SheetXL - v0.3.20
    Preparing search index...

    Interface Collator

    A collator for a Scalar of a specific type.

    Sorting supports sorting across multiple data types. Each collator will have a type.

    interface Collator {
        compare: (a: Scalar, b: Scalar, options?: CollatorOptions) => number;
        defaultOptions?: CollatorOptions;
        type: string;
    }
    Index

    Properties

    compare: (a: Scalar, b: Scalar, options?: CollatorOptions) => number

    Used for sorting. Equal values and null values are presorted and do not need to be handled in the collator implementation.

    Type declaration

      • (a: Scalar, b: Scalar, options?: CollatorOptions): number
      • Parameters

        • a: Scalar
        • b: Scalar
        • Optionaloptions: CollatorOptions

          defaultOptions with any user overrides.

        Returns number

    • Options defined in defaultOptions with any user overrides are passed as the options.
    defaultOptions?: CollatorOptions

    The options passed to the collator.

    type: string

    The ScalarType that this collator can understand or a 'string' that represent the type for `ScalarType.RichData;