Interface UcDeserializer<T, TInput>

Data deserializer.

Reads the data value from the given input. Deserializer may be either synchronous or asynchronous depending on input type.

Type Parameters

  • out T

    Deserialized data type.

  • in TInput = string

Hierarchy

  • UcDeserializer
  • Reads the data synchronously from the given string or array of tokens.

    Parameters

    • input: string | readonly UcToken[]

      Either input string or array of tokens to parse.

    • Optional options: UcDeserializer.Options

      Deserialization options.

      Optional

    Returns T

    Deserialized data value.

  • Reads the data asynchronously from the given readable stream.

    Scans input stream for tokens and reads the encoded data.

    Parameters

    • stream: ReadableStream<string>

      Input stream to read the data from.

    • Optional options: UcDeserializer.Options

      Deserialization options.

      Optional

    Returns Promise<T>

    Promise resolved to deserialized data value.

Properties

__UcDeserializerByTokens__: false

Brand property not supposed to be declared.

Generated using TypeDoc