Skip to main content

JetroEngine

Struct JetroEngine 

Source
pub struct JetroEngine { /* private fields */ }
Expand description

Long-lived multi-document query engine with an explicit plan cache. Use when the same process evaluates many expressions over many documents — parse/lower/compile work is amortised by this object, not hidden in thread-local state.

Implementations§

Source§

impl JetroEngine

Source

pub fn inspect_query( &self, query: &str, options: InspectOptions, ) -> Result<QueryInspection, JetroEngineError>

Inspect how a query parses, plans, and selects execution metadata.

This is an explicit developer API. Normal query execution does not allocate or populate introspection reports.

Source

pub fn inspect_ndjson_query_with_options( &self, query: &str, source: NdjsonSourceMode, ndjson_options: NdjsonOptions, level: InspectLevel, ) -> Result<QueryInspection, JetroEngineError>

Inspect an NDJSON query with explicit NDJSON source options.

Source

pub fn new() -> Self

Create a JetroEngine with the default plan-cache limit of 256 entries.

Source

pub fn with_plan_cache_limit(plan_cache_limit: usize) -> Self

Create a JetroEngine with an explicit plan-cache capacity. Set plan_cache_limit to 0 to disable caching entirely.

Source

pub fn keys(&self) -> &Arc<KeyCache>

Borrow this engine’s JSON key-intern cache.

Source

pub fn clear_cache(&self)

Discard all cached query plans and the engine’s key-intern cache, forcing re-compilation and re-interning on the next call.

Source

pub fn parse_value(&self, document: Value) -> Jetro

Build a Jetro document from a serde_json::Value with object keys interned into this engine’s key cache. Use this in place of Jetro::from(...) / the From<serde_json::Value> impl when per-engine key isolation is required.

Source

pub fn parse_bytes(&self, bytes: Vec<u8>) -> Result<Jetro, JetroEngineError>

Parse raw JSON bytes into a Jetro document with object keys interned into this engine’s key cache. With simd-json, the tape is materialised eagerly so interning happens once at parse time (subsequent collect calls reuse the cached Val tree).

Source

pub fn collect<S: AsRef<str>>( &self, document: &Jetro, expr: S, ) -> Result<Value, EvalError>

Evaluate a Jetro expression against an already-constructed Jetro document, using the engine’s shared plan cache and VM.

Source

pub fn collect_value<S: AsRef<str>>( &self, document: Value, expr: S, ) -> Result<Value, EvalError>

Convenience wrapper: wrap a serde_json::Value in a Jetro and evaluate expr. Routes through JetroEngine::parse_value so the document’s object keys are interned into this engine’s key cache.

Source

pub fn collect_bytes<S: AsRef<str>>( &self, bytes: Vec<u8>, expr: S, ) -> Result<Value, JetroEngineError>

Parse raw JSON bytes into a Jetro document and evaluate expr, returning a JetroEngineError on either parse or evaluation failure. Routes through JetroEngine::parse_bytes so the document’s object keys are interned into this engine’s key cache.

Source

pub fn run_ndjson<R, W>( &self, reader: R, query: &str, writer: W, ) -> Result<usize, JetroEngineError>
where R: BufRead, W: Write,

Evaluate query independently for every non-empty NDJSON row and write one JSON result per output line.

Source

pub fn run_ndjson_file<P, W>( &self, path: P, query: &str, writer: W, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Open an NDJSON file and evaluate query independently for every non-empty row, writing one JSON result per output line.

Source

pub fn run_ndjson_file_with_options<P, W>( &self, path: P, query: &str, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_file with explicit NDJSON reader options.

Source

pub fn run_ndjson_file_with_report<P, W>( &self, path: P, query: &str, writer: W, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where P: AsRef<Path>, W: Write,

Evaluate a file-backed NDJSON query and return a route/counter report.

Source

pub fn run_ndjson_file_with_report_and_options<P, W>( &self, path: P, query: &str, writer: W, options: NdjsonOptions, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_file_with_report with explicit options.

Source

pub fn run_ndjson_file_limit<P, W>( &self, path: P, query: &str, limit: usize, writer: W, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Open an NDJSON file, write at most limit query results, and stop reading.

Source

pub fn run_ndjson_file_limit_with_options<P, W>( &self, path: P, query: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_file_limit with explicit NDJSON reader options.

Source

pub fn run_ndjson_file_limit_with_report<P, W>( &self, path: P, query: &str, limit: usize, writer: W, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where P: AsRef<Path>, W: Write,

Evaluate a limited file-backed NDJSON query and return a route/counter report.

Source

pub fn run_ndjson_file_limit_with_report_and_options<P, W>( &self, path: P, query: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where P: AsRef<Path>, W: Write,

Source

pub fn run_ndjson_source<W>( &self, source: NdjsonSource, query: &str, writer: W, ) -> Result<usize, JetroEngineError>
where W: Write,

Evaluate query independently for every row from an io::NdjsonSource.

Source

pub fn run_ndjson_source_with_options<W>( &self, source: NdjsonSource, query: &str, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where W: Write,

Like JetroEngine::run_ndjson_source with explicit NDJSON reader options.

Source

pub fn run_ndjson_source_with_report<W>( &self, source: NdjsonSource, query: &str, writer: W, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where W: Write,

Evaluate an io::NdjsonSource query and return a route/counter report.

Source

pub fn run_ndjson_source_with_report_and_options<W>( &self, source: NdjsonSource, query: &str, writer: W, options: NdjsonOptions, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where W: Write,

Like JetroEngine::run_ndjson_source_with_report with explicit options.

Source

pub fn run_ndjson_source_limit<W>( &self, source: NdjsonSource, query: &str, limit: usize, writer: W, ) -> Result<usize, JetroEngineError>
where W: Write,

Evaluate query for rows from an io::NdjsonSource, write at most limit results, and stop reading.

Source

pub fn run_ndjson_source_limit_with_options<W>( &self, source: NdjsonSource, query: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where W: Write,

Like JetroEngine::run_ndjson_source_limit with explicit NDJSON reader options.

Source

pub fn run_ndjson_source_limit_with_report<W>( &self, source: NdjsonSource, query: &str, limit: usize, writer: W, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where W: Write,

Evaluate a limited io::NdjsonSource query and return a route/counter report.

Source

pub fn run_ndjson_source_limit_with_report_and_options<W>( &self, source: NdjsonSource, query: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where W: Write,

Source

pub fn run_ndjson_rev<P, W>( &self, path: P, query: &str, writer: W, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Read an NDJSON file from tail to head and write one query result per row.

Source

pub fn run_ndjson_rev_with_options<P, W>( &self, path: P, query: &str, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_rev with explicit NDJSON reader options.

Source

pub fn run_ndjson_rev_limit<P, W>( &self, path: P, query: &str, limit: usize, writer: W, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Read an NDJSON file from tail to head, write at most limit query results, and stop reading.

Source

pub fn run_ndjson_rev_limit_with_options<P, W>( &self, path: P, query: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_rev_limit with explicit NDJSON reader options.

Source

pub fn run_ndjson_rev_distinct_by<P, W>( &self, path: P, key_query: &str, query: &str, limit: usize, writer: W, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Read an NDJSON file from tail to head, keep only the first row seen for each key_query result in that reverse stream order, write query for retained rows, and stop after limit retained rows.

Source

pub fn run_ndjson_rev_distinct_by_with_options<P, W>( &self, path: P, key_query: &str, query: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_rev_distinct_by with explicit NDJSON reader options.

Source

pub fn run_ndjson_rev_distinct_by_with_stats<P, W>( &self, path: P, key_query: &str, query: &str, limit: usize, writer: W, ) -> Result<NdjsonRevDistinctStats, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_rev_distinct_by, returning execution counters for path-selection and duplicate-drop observability.

Source

pub fn run_ndjson_rev_distinct_by_with_stats_and_options<P, W>( &self, path: P, key_query: &str, query: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<NdjsonRevDistinctStats, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_rev_distinct_by_with_stats with explicit NDJSON reader options.

Source

pub fn run_ndjson_rev_distinct_by_with_report<P, W>( &self, path: P, key_query: &str, query: &str, limit: usize, writer: W, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_rev_distinct_by, returning the shared NDJSON execution report shape.

Source

pub fn run_ndjson_rev_distinct_by_with_report_and_options<P, W>( &self, path: P, key_query: &str, query: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where P: AsRef<Path>, W: Write,

Source

pub fn run_ndjson_with_options<R, W>( &self, reader: R, query: &str, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where R: BufRead, W: Write,

Like JetroEngine::run_ndjson with explicit NDJSON reader options.

Source

pub fn run_ndjson_with_report<R, W>( &self, reader: R, query: &str, writer: W, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where R: BufRead, W: Write,

Evaluate query for NDJSON rows and return a route/counter report.

Source

pub fn run_ndjson_with_report_and_options<R, W>( &self, reader: R, query: &str, writer: W, options: NdjsonOptions, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where R: BufRead, W: Write,

Like JetroEngine::run_ndjson_with_report with explicit NDJSON reader options.

Source

pub fn run_ndjson_limit<R, W>( &self, reader: R, query: &str, limit: usize, writer: W, ) -> Result<usize, JetroEngineError>
where R: BufRead, W: Write,

Evaluate query for NDJSON rows, write at most limit results, and stop reading.

Source

pub fn run_ndjson_limit_with_options<R, W>( &self, reader: R, query: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where R: BufRead, W: Write,

Like JetroEngine::run_ndjson_limit with explicit NDJSON reader options.

Source

pub fn run_ndjson_limit_with_report<R, W>( &self, reader: R, query: &str, limit: usize, writer: W, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where R: BufRead, W: Write,

Evaluate a limited NDJSON reader query and return a route/counter report.

Source

pub fn run_ndjson_limit_with_report_and_options<R, W>( &self, reader: R, query: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where R: BufRead, W: Write,

Like JetroEngine::run_ndjson_limit_with_report with explicit options.

Source

pub fn run_ndjson_matches<R, W>( &self, reader: R, predicate: &str, limit: usize, writer: W, ) -> Result<usize, JetroEngineError>
where R: BufRead, W: Write,

Evaluate predicate for each NDJSON row, write matching original rows, and stop after limit matches.

Source

pub fn run_ndjson_matches_with_options<R, W>( &self, reader: R, predicate: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where R: BufRead, W: Write,

Like JetroEngine::run_ndjson_matches with explicit NDJSON reader options.

Source

pub fn run_ndjson_matches_with_report<R, W>( &self, reader: R, predicate: &str, limit: usize, writer: W, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where R: BufRead, W: Write,

Evaluate a match-limited NDJSON query and return the shared execution report.

Source

pub fn run_ndjson_matches_with_report_and_options<R, W>( &self, reader: R, predicate: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where R: BufRead, W: Write,

Like JetroEngine::run_ndjson_matches_with_report with explicit options.

Source

pub fn run_ndjson_matches_file<P, W>( &self, path: P, predicate: &str, limit: usize, writer: W, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Open an NDJSON file, write matching original rows, and stop after limit matches.

Source

pub fn run_ndjson_matches_file_with_options<P, W>( &self, path: P, predicate: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_matches_file with explicit NDJSON reader options.

Source

pub fn run_ndjson_matches_file_with_report<P, W>( &self, path: P, predicate: &str, limit: usize, writer: W, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_matches_file, returning the shared report.

Source

pub fn run_ndjson_matches_file_with_report_and_options<P, W>( &self, path: P, predicate: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where P: AsRef<Path>, W: Write,

Source

pub fn run_ndjson_matches_source<W>( &self, source: NdjsonSource, predicate: &str, limit: usize, writer: W, ) -> Result<usize, JetroEngineError>
where W: Write,

Evaluate predicate against each row from an io::NdjsonSource, write matching original rows, and stop after limit matches.

Source

pub fn run_ndjson_matches_source_with_options<W>( &self, source: NdjsonSource, predicate: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where W: Write,

Like JetroEngine::run_ndjson_matches_source with explicit NDJSON reader options.

Source

pub fn run_ndjson_matches_source_with_report<W>( &self, source: NdjsonSource, predicate: &str, limit: usize, writer: W, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where W: Write,

Like JetroEngine::run_ndjson_matches_source, returning the shared report.

Source

pub fn run_ndjson_matches_source_with_report_and_options<W>( &self, source: NdjsonSource, predicate: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where W: Write,

Source

pub fn run_ndjson_rev_matches<P, W>( &self, path: P, predicate: &str, limit: usize, writer: W, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Read an NDJSON file from tail to head, write matching original rows, and stop after limit matches.

Source

pub fn run_ndjson_rev_matches_with_options<P, W>( &self, path: P, predicate: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_rev_matches with explicit NDJSON reader options.

Source

pub fn run_ndjson_rev_matches_with_report<P, W>( &self, path: P, predicate: &str, limit: usize, writer: W, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where P: AsRef<Path>, W: Write,

Like JetroEngine::run_ndjson_rev_matches, returning the shared report.

Source

pub fn run_ndjson_rev_matches_with_report_and_options<P, W>( &self, path: P, predicate: &str, limit: usize, writer: W, options: NdjsonOptions, ) -> Result<NdjsonExecutionReport, JetroEngineError>
where P: AsRef<Path>, W: Write,

Source

pub fn collect_ndjson<R>( &self, reader: R, query: &str, ) -> Result<Vec<Value>, JetroEngineError>
where R: BufRead,

Evaluate query independently for every non-empty NDJSON row and collect the per-row results.

Source

pub fn collect_ndjson_file<P>( &self, path: P, query: &str, ) -> Result<Vec<Value>, JetroEngineError>
where P: AsRef<Path>,

Open an NDJSON file and collect per-row query results.

Source

pub fn collect_ndjson_file_with_options<P>( &self, path: P, query: &str, options: NdjsonOptions, ) -> Result<Vec<Value>, JetroEngineError>
where P: AsRef<Path>,

Like JetroEngine::collect_ndjson_file with explicit NDJSON reader options.

Source

pub fn collect_ndjson_source( &self, source: NdjsonSource, query: &str, ) -> Result<Vec<Value>, JetroEngineError>

Collect per-row query results from an io::NdjsonSource.

Source

pub fn collect_ndjson_source_with_options( &self, source: NdjsonSource, query: &str, options: NdjsonOptions, ) -> Result<Vec<Value>, JetroEngineError>

Like JetroEngine::collect_ndjson_source with explicit NDJSON reader options.

Source

pub fn collect_ndjson_rev<P>( &self, path: P, query: &str, ) -> Result<Vec<Value>, JetroEngineError>
where P: AsRef<Path>,

Read an NDJSON file from tail to head and collect per-row query results.

Source

pub fn collect_ndjson_rev_with_options<P>( &self, path: P, query: &str, options: NdjsonOptions, ) -> Result<Vec<Value>, JetroEngineError>
where P: AsRef<Path>,

Like JetroEngine::collect_ndjson_rev with explicit NDJSON reader options.

Source

pub fn for_each_ndjson_rev<P, F>( &self, path: P, query: &str, f: F, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, F: FnMut(Value),

Read an NDJSON file from tail to head and call f with each query result as it is produced.

Source

pub fn for_each_ndjson_rev_until<P, F>( &self, path: P, query: &str, f: F, ) -> Result<usize, JetroEngineError>

Read an NDJSON file from tail to head and call f until it returns io::NdjsonControl::Stop or input is exhausted.

Source

pub fn for_each_ndjson_rev_until_with_options<P, F>( &self, path: P, query: &str, options: NdjsonOptions, f: F, ) -> Result<usize, JetroEngineError>

Like JetroEngine::for_each_ndjson_rev_until with explicit NDJSON reader options.

Source

pub fn for_each_ndjson_rev_with_options<P, F>( &self, path: P, query: &str, options: NdjsonOptions, f: F, ) -> Result<usize, JetroEngineError>
where P: AsRef<Path>, F: FnMut(Value),

Like JetroEngine::for_each_ndjson_rev with explicit NDJSON reader options.

Source

pub fn collect_ndjson_with_options<R>( &self, reader: R, query: &str, options: NdjsonOptions, ) -> Result<Vec<Value>, JetroEngineError>
where R: BufRead,

Like JetroEngine::collect_ndjson with explicit NDJSON reader options.

Source

pub fn collect_ndjson_matches<R>( &self, reader: R, predicate: &str, limit: usize, ) -> Result<Vec<Value>, JetroEngineError>
where R: BufRead,

Evaluate predicate for each NDJSON row, collect matching original rows, and stop after limit matches.

Source

pub fn collect_ndjson_matches_with_options<R>( &self, reader: R, predicate: &str, limit: usize, options: NdjsonOptions, ) -> Result<Vec<Value>, JetroEngineError>
where R: BufRead,

Like JetroEngine::collect_ndjson_matches with explicit NDJSON reader options.

Source

pub fn collect_ndjson_matches_file<P>( &self, path: P, predicate: &str, limit: usize, ) -> Result<Vec<Value>, JetroEngineError>
where P: AsRef<Path>,

Open an NDJSON file, collect matching original rows, and stop after limit matches.

Source

pub fn collect_ndjson_matches_file_with_options<P>( &self, path: P, predicate: &str, limit: usize, options: NdjsonOptions, ) -> Result<Vec<Value>, JetroEngineError>
where P: AsRef<Path>,

Like JetroEngine::collect_ndjson_matches_file with explicit NDJSON reader options.

Source

pub fn collect_ndjson_matches_source( &self, source: NdjsonSource, predicate: &str, limit: usize, ) -> Result<Vec<Value>, JetroEngineError>

Evaluate predicate against each row from an io::NdjsonSource, collect matching original rows, and stop after limit matches.

Source

pub fn collect_ndjson_matches_source_with_options( &self, source: NdjsonSource, predicate: &str, limit: usize, options: NdjsonOptions, ) -> Result<Vec<Value>, JetroEngineError>

Like JetroEngine::collect_ndjson_matches_source with explicit NDJSON reader options.

Source

pub fn collect_ndjson_rev_matches<P>( &self, path: P, predicate: &str, limit: usize, ) -> Result<Vec<Value>, JetroEngineError>
where P: AsRef<Path>,

Read an NDJSON file from tail to head, collect matching original rows, and stop after limit matches.

Source

pub fn collect_ndjson_rev_matches_with_options<P>( &self, path: P, predicate: &str, limit: usize, options: NdjsonOptions, ) -> Result<Vec<Value>, JetroEngineError>
where P: AsRef<Path>,

Like JetroEngine::collect_ndjson_rev_matches with explicit NDJSON reader options.

Source

pub fn for_each_ndjson<R, F>( &self, reader: R, query: &str, f: F, ) -> Result<usize, JetroEngineError>
where R: BufRead, F: FnMut(Value),

Evaluate query independently for every non-empty NDJSON row and call f with each result as it is produced.

Source

pub fn for_each_ndjson_until<R, F>( &self, reader: R, query: &str, f: F, ) -> Result<usize, JetroEngineError>

Evaluate query independently for every non-empty NDJSON row and call f until it returns io::NdjsonControl::Stop or input is exhausted.

Source

pub fn for_each_ndjson_source<F>( &self, source: NdjsonSource, query: &str, f: F, ) -> Result<usize, JetroEngineError>
where F: FnMut(Value),

Evaluate query for every row from an io::NdjsonSource and call f with each result as it is produced.

Source

pub fn for_each_ndjson_source_until<F>( &self, source: NdjsonSource, query: &str, f: F, ) -> Result<usize, JetroEngineError>

Evaluate query for every row from an io::NdjsonSource and call f until it returns io::NdjsonControl::Stop or input is exhausted.

Source

pub fn for_each_ndjson_source_until_with_options<F>( &self, source: NdjsonSource, query: &str, options: NdjsonOptions, f: F, ) -> Result<usize, JetroEngineError>

Like JetroEngine::for_each_ndjson_source_until with explicit NDJSON reader options.

Source

pub fn for_each_ndjson_source_with_options<F>( &self, source: NdjsonSource, query: &str, options: NdjsonOptions, f: F, ) -> Result<usize, JetroEngineError>
where F: FnMut(Value),

Like JetroEngine::for_each_ndjson_source with explicit NDJSON reader options.

Source

pub fn for_each_ndjson_with_options<R, F>( &self, reader: R, query: &str, options: NdjsonOptions, f: F, ) -> Result<usize, JetroEngineError>
where R: BufRead, F: FnMut(Value),

Like JetroEngine::for_each_ndjson with explicit NDJSON reader options.

Source

pub fn for_each_ndjson_until_with_options<R, F>( &self, reader: R, query: &str, options: NdjsonOptions, f: F, ) -> Result<usize, JetroEngineError>

Like JetroEngine::for_each_ndjson_until with explicit NDJSON reader options.

Trait Implementations§

Source§

impl Default for JetroEngine

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.