Function dateToLocktimeBin

  • Convert a JavaScript Date object to its equivalent transaction locktime bytecode representation. The date is rounded to the nearest second (the precision of locktime Dates).

    Note: a block-based locktime can simply be encoded with numberToBinUint32LE (provided it is no larger than the maximum, 499999999).

    Parameters

    • date: Date

      the Date to convert to a locktime Uint8Array

    Returns Uint8Array | dateOutOfRange

Generated using TypeDoc