UNPKG

@jahed/sparql-engine

Version:

SPARQL query engine for servers and web browsers.

18 lines (17 loc) 1.02 kB
import ExecutionContext from "../../engine/context/execution-context.ts"; import type { PipelineStage } from "../../engine/pipeline/pipeline-engine.ts"; import { Bindings } from "../../rdf/bindings.ts"; import Graph from "../../rdf/graph.ts"; import type { EngineTriple } from "../../types.ts"; /** * Perform a join between a source of solution bindings (left relation) * and a triple pattern (right relation) using the Index Nested Loop Join algorithm. * This algorithm is more efficient if the cardinality of the left relation is smaller * than the cardinality of the right one. * @param source - Left input (a {@link PipelineStage}) * @param pattern - Triple pattern to join with (right relation) * @param graph - RDF Graph on which the join is performed * @param context - Execution context * @return A {@link PipelineStage} which evaluate the join */ export default function indexJoin(source: PipelineStage<Bindings>, pattern: EngineTriple, graph: Graph, context: ExecutionContext): PipelineStage<Bindings>;