proposit-core
    Preparing search index...

    Interface TClaimConnectionLibraryManagement<TConn>

    Full management interface for a claim-connection library. Extends TClaimConnectionLookup with mutation, query, and snapshot methods. Connections are create-or-delete only — no update path.

    interface TClaimConnectionLibraryManagement<
        TConn extends TCoreClaimConnection = TCoreClaimConnection,
    > {
        add(connection: Omit<TConn, "checksum">): TConn;
        filter(predicate: (c: TConn) => boolean): TConn[];
        get(id: string): TConn | undefined;
        getAll(): TConn[];
        getConnectionsForClaim(claimId: string): TConn[];
        remove(id: string): TConn;
        snapshot(): TClaimConnectionLibrarySnapshot<TConn>;
        validate(): TInvariantValidationResult;
    }

    Type Parameters

    Hierarchy (View Summary)

    Implemented by

    Index

    Methods

    • Creates a claim connection. Implementations validate that both the supported and supporting claims exist in the underlying claim library and that the supporting-side claim has the type required by this specialization (e.g. 'citation' for ClaimCitationLibrary, 'axiomatic' for ClaimAxiomLibrary). Citation libraries also reject any edge that would introduce a cycle in the global claim-citation graph.

      Parameters

      • connection: Omit<TConn, "checksum">

        The connection data without the checksum field.

      Returns TConn

      The created connection with checksum populated.

      If a connection with the same ID already exists.

      If either referenced claim does not exist in the claim library.

      If the supporting-side claim has the wrong type for this specialization.

      If the connection would create a cycle (citation library only).