This is the base engine of DataCube, it provides capabilities that DataCube cannot itself handle, such as query execution, compilation, etc.

Note that we want to make sure this class is stateless, since from the perspective of DataCube, the engine simply should not hold any state. This does not mean any implementations of this engine must be stateless as well, that's totally up to their authors.

Methods

  • By default, for a function chain, Pure grammar composer will extract the first parameter of the first function and render it as the caller of that function rather than a parameter e.g. fx(fy(p1, p2), p3) will be rendered as p1->fy(p2)->fx(p3) instead of fy(p1, p2)-> fx(p3)

    We do a hack to get around this by setting a dummy value as the first parameter of the first function in the chain. Then remove this dummy value from the final code.

    Parameters

    • snapshot: DataCubeQuerySnapshot
    • Optionalpretty: boolean

    Returns Promise<string>