Options
All
  • Public
  • Public/Protected
  • All
Menu

Class LogSerializer<TValue>

Serializes and deserializes log lines

Type parameters

  • TValue

Hierarchy

  • LogSerializer

Index

Constructors

constructor

Methods

deserializeOperation

  • deserializeOperation(log: string): Operation

deserializeRemove

  • deserializeRemove(log: string): string | null
  • Deserializes a log line into a key

    Parameters

    • log: string

      The log line

    Returns string | null

deserializeSet

  • deserializeSet<T>(log: string): StoragePair<T> | null
  • Deserializes a log line to a key and a value

    Type parameters

    • T: TValue

    Parameters

    • log: string

      The log line

    Returns StoragePair<T> | null

serializeRemove

  • serializeRemove(key: string): string
  • Serializes a key into the writable format: ""

    Parameters

    • key: string

      The key to serialize

    Returns string

serializeSet

  • serializeSet<T>(key: string, value: T): string
  • Serializes a key and value pair into the writable format: "<KEY>":<VALUE>

    Type parameters

    • T: TValue

    Parameters

    • key: string

      The key

    • value: T

      The value

    Returns string

Generated using TypeDoc