• If the index forms an algebraic group, return the result of appending all values.

    Assuming O(1) append and inverse, this index has O(1) memory and time complexity for queries and updates.

    Type Parameters

    • State

    • Return

    Parameters

    • args: {
          append: ((a, b) => State);
          empty: State;
          inverse: ((a) => State);
          result: ((a) => Return);
      }
      • append: ((a, b) => State)
          • (a, b): State
          • Parameters

            • a: State
            • b: State

            Returns State

      • empty: State
      • inverse: ((a) => State)
          • (a): State
          • Parameters

            • a: State

            Returns State

      • result: ((a) => Return)
          • (a): Return
          • Parameters

            • a: State

            Returns Return

    Returns UnregisteredAggregateIndex<State, Return>

Generated using TypeDoc