Function swapMultiples

  • Swaps the order of contiguous bytes in a sequence of bytes that are divisible by a given multiple value.
    Used when encrypting and decrypting packets and data files.

    Example

    multiple = 3
    {10, 21, 27} → {10, 27, 21}

    Remarks

    This is an in-place operation.

    Parameters

    • data: Uint8Array

      the data to swap bytes in

    • multiple: number

      the multiple value

    Returns void

Generated using TypeDoc