Class RepresentationMetadata

Stores the metadata triples and provides methods for easy access. Most functions return the metadata object to allow for chaining.

Hierarchy

  • RepresentationMetadata

Constructors

Properties

id: BlankNode | NamedNode<string>
logger: Logger = ...
store: Store<Quad, Quad, Quad, Quad>

Accessors

Methods

  • Throws

    Error If there are multiple matching values.

    Parameters

    • predicate: NamedNode<string>

      Predicate to get the value for.

    • Optional graph: MetadataGraph

      Optional graph where the triple should be found.

    Returns undefined | Term

    The corresponding value. Undefined if there is no match

  • Finds all object values matching the given predicate and/or graph.

    Parameters

    • predicate: NamedNode<string>

      Optional predicate to get the values for.

    • Optional graph: MetadataGraph

      Optional graph where to get from.

    Returns Term[]

    An array with all matches.

  • Verifies if a specific triple can be found in the metadata. Undefined parameters are interpreted as wildcards.

    Parameters

    • predicate: null | string | NamedNode<string> = null
    • object: null | string | BlankNode | Literal | NamedNode<string> = null
    • graph: null | MetadataGraph = null

    Returns boolean

  • Parameters

    • subject: null | string | BlankNode | NamedNode<string> = null
    • predicate: null | NamedNode<string> = null
    • object: null | string | BlankNode | Literal | NamedNode<string> = null
    • graph: null | MetadataGraph = null

    Returns Quad[]

    All matching metadata quads.