Class GoodDAG<T>

Type Parameters

  • T = string

Hierarchy

  • GoodDAG

Implements

Constructors

Properties

Methods

Constructors

  • Type Parameters

    • T = string

    Parameters

    • rootValue: T
    • blockSize: number = max16

    Returns GoodDAG<T>

Properties

data: DAGData<T>
index: number = 0

Methods

  • add a new entry into the DAG with the supplied value, with this entry as its parent.

    Parameters

    • value: T

    Returns DAGEntry<T>

  • return true if this is the root entry (it is)

    Returns boolean

  • get the parent entry to this one (returns undefined, this is the root)

    Returns undefined

  • get the count of items stored in the DAG

    Returns number

Generated using TypeDoc