sesaparcours
    Preparing search index...
    interface Parser {
        clear: () => void;
        remove: (name: string) => void;
        set: (name: string, value: any) => void;
        evaluate(expr: string | string[]): any;
        get(name: string): any;
        getAll(): { [key: string]: any };
        getAllAsMap(): Map<string, any>;
    }
    Index

    Properties

    clear: () => void

    Completely clear the parser’s scope.

    remove: (name: string) => void

    Remove a variable or function from the parser’s scope.

    Type Declaration

      • (name: string): void
      • Parameters

        • name: string

          The name of the variable or function to be removed

        Returns void

    set: (name: string, value: any) => void

    Set a variable or function in the parser’s scope.

    Type Declaration

      • (name: string, value: any): void
      • Parameters

        • name: string

          The name of the variable or function to be set

        • value: any

          The value of the variable or function to be set

        Returns void

    Methods

    • Evaluate an expression. Returns the result of the expression.

      Parameters

      • expr: string | string[]

        The expression to evaluate

      Returns any

    • Retrieve a variable or function from the parser’s scope.

      Parameters

      • name: string

        The name of the variable or function to be retrieved

      Returns any

    • Retrieve an object with all defined variables in the parser’s scope.

      Returns { [key: string]: any }

      An object with all defined variables

    • Retrieve a map with all defined variables in the parser’s scope.

      Returns Map<string, any>