proposit-core
    Preparing search index...

    Interface TVariableReferences<TArg, TPremise, TExpr, TVar>

    Variable reference queries and cascade deletion.

    interface TVariableReferences<
        TArg extends TCoreArgument = TCoreArgument,
        TPremise extends TCorePremise = TCorePremise,
        TExpr extends TCorePropositionalExpression = TCorePropositionalExpression,
        TVar extends TCorePropositionalVariable = TCorePropositionalVariable,
    > {
        deleteExpressionsUsingVariable(
            variableId: string,
        ): TCoreMutationResult<TExpr[], TExpr, TVar, TPremise, TArg>;
        getReferencedVariableIds(): Set<string>;
        getVariables(): TVar[];
    }

    Type Parameters

    Implemented by

    Index

    Methods

    • Returns the set of variable IDs referenced by expressions in this premise. Only variables that appear in type: "variable" expression nodes are included.

      Returns Set<string>

      A Set of referenced variable ID strings.

    • Returns all argument-level variables (from the shared VariableManager) sorted by ID. Since the VariableManager is shared across all premises, this returns every registered variable — not just those referenced by expressions in this premise.

      Returns TVar[]

      An array of variable entities.