View Source Dequel.Query.Context (Dequel v0.7.0)
Tracks joins and bindings during query building for relationship filtering.
When building queries with nested field paths like author.address.city,
this module tracks which joins are needed and ensures joins are only
created once per unique path.
Summary
Functions
Adds a preload path to the context
Ensures joins exist for a field path, returns {binding, updated_context}.
Creates a new empty context with optional schema for semantic analysis
Creates a new context with schema and prefix
Returns joins in dependency order (parent joins first)
Types
Functions
Adds a preload path to the context
Ensures joins exist for a field path, returns {binding, updated_context}.
For simple fields (atoms) or single-segment paths, returns the base binding :q. For multi-segment paths, registers necessary joins and returns the binding for the deepest association.
Creates a new empty context with optional schema for semantic analysis
Creates a new context with schema and prefix
Returns joins in dependency order (parent joins first)