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

    Interface ISnapshot

    Represents an immutable reference to an Record, capturing its content and metadata.

    interface ISnapshot {
        isISnapshot: true;
        copyTo(
            destination: ITable.SnapshotDestination,
            options?: CopyOptions,
        ): Promise<Coords>;
        getCoords?(): Readonly<C>;
        getMarkOptions(): CopyOptions;
        getName?(): string;
        getSource(): ITable;
        toHtml?(): string | Promise<string>;
        toImage?(): Blob | Promise<Blob>;
        toJSON?(): any;
        toText?(): string | Promise<string>;
    }

    Hierarchy (View Summary)

    Index
    isISnapshot: true

    For runtime type checking.

    • Copies, or moves, the table to the destination.

      Parameters

      Returns Promise<Coords>

      The table's cells are expected at the destination already: the table takes its header, body and totals rows from what is there.

      With isCut the source table is moved. Within its own sheet it is the same table at a new place, so its name and the references to it stay as they are; anywhere else it is removed and added again under its name.

    • Retrieves the coordinates that bound the current snapshot.

      Returns Readonly<C>

      Different types of snapshots may have different coordinate systems.

    • Return the options used when creating.

      Returns CopyOptions

      This is done so that we can create a copy.

    • A user friendly name of a the snapshot item.

      Returns string

    • Converts the snapshot to an HTML representation.

      Returns string | Promise<string>

      A string or promise resolving to the HTML representation of the snapshot.

    • Converts the snapshot to an image blob.

      Returns Blob | Promise<Blob>

      A Blob or promise resolving to the image representation of the snapshot.

    • Converts the snapshot to a JSON object.

      Returns any

      A JSON object or promise resolving to the JSON representation of the snapshot.

    • Converts the snapshot to a plain text representation.

      Returns string | Promise<string>

      A string or promise resolving to the text representation of the snapshot.