Skip to main content

TxFnExpander

Trait TxFnExpander 

Source
pub trait TxFnExpander: Send + Sync {
    // Required method
    fn expand(&self, db: &Db, forms: Vec<Edn>) -> Result<Vec<Edn>, String>;
}
Expand description

Expands user database-function invocations in boundary EDN transaction forms before native conversion. Implemented by corium-cljrs (the sandboxed Clojurust host, ADR-0008) and injected by the process wiring; the transactor itself stays free of cljrs dependencies.

Required Methods§

Source

fn expand(&self, db: &Db, forms: Vec<Edn>) -> Result<Vec<Edn>, String>

Rewrites forms with every [:my/fn arg…] invocation replaced by the function’s returned tx-data (recursively).

§Errors

Returns a display message when a function is missing, rejected by the sandbox, fails, or exceeds its budget; the transaction aborts.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§