Interface AttributeListModel<K, T>

A list object of attributes commonly specified for nodes, subgraphs, and edges under graph and subgraph.

interface AttributeListModel<K, T> {
    $$kind: K;
    $$type: "AttributeList";
    comment?: string;
    size: number;
    values: readonly [T, Attribute<T>][];
    apply(attributes): void;
    clear(): void;
    delete(key): void;
    get<K>(key): undefined | Attribute<K>;
    set<K>(key, value): void;
}

Type Parameters

Hierarchy (view full)

Implemented by

Properties

$$kind: K
$$type: "AttributeList"

The type of the DotObjectType.

comment?: string

Comments to include when outputting with toDot.

size: number

Size of the set of keys and values held by the DOT object.

values: readonly [T, Attribute<T>][]

The key/value tuples of the object attributes.

Methods

  • Apply keys and values that can be specified for DOT objects collectively.

    Parameters

    Returns void

  • Delete all attributes specified for the DOT object.

    Returns void

  • Delete the value of an attribute from a DOT object by specifying a key.

    Parameters

    • key: T

    Returns void

  • Get the value of an attribute by a DOT object by specifying its key.

    If the value corresponding to the key does not exist, undefined is returned.

    Type Parameters

    Parameters

    • key: K

    Returns undefined | Attribute<K>

  • Set a value, by specifying the key of the attributes in the DOT object.

    Type Parameters

    Parameters

    Returns void

Generated using TypeDoc