cartulary 0.3.0-alpha.1

The knowledge layer of your project — decisions, issues, docs, all in one place.
Documentation
1
2
3
4
5
6
7
8
9
10
11
use crate::domain::model::query::{QueryResult, QuerySchema, QueryScript};

/// Port: run an opaque script body against the workspace's query
/// engine and return a domain-shaped result, and introspect the
/// engine's exposed relations. Decoupled from the engine's value
/// enum (Cozo, SQL, …) on purpose — the adapter converts.
pub trait QueryRunner {
    fn run(&self, script: &QueryScript) -> anyhow::Result<QueryResult>;

    fn schema(&self) -> anyhow::Result<QuerySchema>;
}