SerializationHelpers.announceZeroBasedIndicesFromSignedOneBasedIndices Function

Process 1-based blocked indices into 0-based indices.

announceZeroBasedIndicesFromSignedOneBasedIndices(sourceIndices: Int32Array, numPerBlock: number, announceZeroBasedIndex: (i0: number, flag?: boolean) => any, terminateBlock?: () => any): void

Parameter Type Description
sourceIndices Int32Array signed, 1-based, 0-terminated/padded source indices, blocking specified by numPerBlock
numPerBlock number index blocking: fixed blocks of size numPerBlock > 1, possibly 0-padded; otherwise, variable-sized blocks terminated by 0
announceZeroBasedIndex (i0: number, flag?: boolean) => any callback to receive a 0-based index and optional flag indicating whether the sign of the source index is positive
terminateBlock () => any optional callback called after each index block has been announced

Returns - void

Defined in

Last Updated: 17 December, 2024