g3-toolkit API Reference
    Preparing search index...

    Class HolonicAdapter

    Interface that all data source adapters implement.

    ARGUMENT SAFETY. nodeId, depth and edgeTypes typically come from host state (a node click, a search result, a server payload), so the remote adapters treat them as untrusted: values are bound through the protocol's own mechanism where one exists, and validated by ./query-safety where it does not. A value that cannot be placed safely raises AdapterArgumentError before any request is sent. query(q) is the exception and is NOT sanitized: its argument is query text by definition, so hosts must not build it from untrusted input.

    Implements

    Index

    Constructors

    Properties

    id: "holonic"

    Short identifier (e.g., "sparql", "cypher", "holonic").

    name: "Holonic Dataset"

    Human-readable name (e.g., "SPARQL Endpoint").

    Methods

    • Project the holon's interior. DEPTH IS REJECTED ABOVE 1 rather than ignored.

      This adapter's expansion is a drill-down into one holon, so there is no hop count to honor. A multi-hop holarchy neighborhood would have to traverse portals and then link the interiors it collected, and the linkage lives in the boundary and projection graphs that the simplified HolonicDataset above deliberately does not carry (see the SCOPE note in this file's header, and R5.1). Unioning interiors without it would return disconnected components and call them a neighborhood.

      Silently discarding the argument was the prior behavior: a host wiring a "expand 2 hops" action got one hop and no signal. A throw puts the failure at the call site that supplied the value.

      Parameters

      • holonId: string
      • depth: number = 1

      Returns Promise<UGM>

      AdapterArgumentError when depth resolves above 1.

    • NOTE: the in-memory dataset has no query engine; the query string is currently ignored and the top-level holarchy projection is returned. Callers that need real query semantics should use a backend-connected adapter. Logged (not thrown) so existing view wiring keeps working while making the limitation observable.

      Parameters

      • q: string

      Returns Promise<UGM>