SheetXL - v0.8.0-beta.9+sites.210.e2d420901
    Preparing search index...

    Interface IteratorContext

    Provides access to cell-specific information and utility functions during range iteration.

    This object serves as a context in the iterator, offering a convenient way to retrieve the cell's coordinates, the full ICell object, and perform additional operations like converting values to JavaScript dates or getting the cell's address.

    interface IteratorContext {
        getAddress(coords?: Partial<FixableCellCoords>, r1c1?: boolean): string;
        getCell(): ICell;
        getCoords(): CellCoords;
        getInjectedReference<T = any>(index: number): T | undefined;
        getInteropType(): InteropScalarType;
        getInteropValue(): InteropScalar;
        getType(): ScalarType;
    }
    Index
    • Converts the given or current cell coordinates to their corresponding A1-style address string (e.g., 'A1').

      Parameters

      • Optionalcoords: Partial<FixableCellCoords>

        The coordinates to convert. If not provided, the coordinates of the current cell in the iteration will be used.

      • Optionalr1c1: boolean

        If unspecified defaults to the environment's default format.

      Returns string

      The address string representing the cell coordinates.

      The returned address can be used for further range queries or operations within the spreadsheet.

    • Retrieves the ICell associated with the current iteration.

      Returns ICell

      ICells are dynamically created and are significantly slower to access than simple values.

    • Retrieves the IRange.CellCoords associated with the current iteration.

      Returns CellCoords

    • Returns a custom referenced entry for the cell.

      Type Parameters

      • T = any

      Parameters

      • index: number

        The index used with setting the injected reference.

      Returns T | undefined

    • Returns the InteropScalarType of the value, which provides more detailed type information than getType(), such as distinguishing between dates and numbers.

      Returns InteropScalarType

    • Returns the current cell's value as an InteropScalar, which includes both the raw value and its associated type information.

      Returns InteropScalar

    • Return the ScalarType of the value.

      Returns ScalarType