Function prepare

  • Prepare a message as a ISO buffer before sending it to the ISO capable server/client

    Returns

    a buffer to the ISO message

    Example

    const iso = Buffer.from("0100ca......", "hex");
    const message = parse(isoDefinition, buffer);
    message.content[2] = "576aze45623";
    const newIso = prepare(isoDefinition, message);

    Type Parameters

    Parameters

    • definition: MessageDefinition<FD>

      an object that will constrain the type of the fields that can be used. It will be used while preparing the buffer

    • message: Message<FD>

      the message that we want to write in an ISO format

    Returns Buffer

Generated using TypeDoc