pub fn validate_read_only_with(
query: &CypherQuery,
is_write_procedure: &dyn Fn(&str) -> bool,
) -> Result<(), String>Expand description
Like validate_read_only, but also rejects procedure calls that
is_write_procedure classifies as mutating.
The predicate receives the procedure name (e.g. "db.create.something") and
returns true if invoking it could mutate the graph or schema. Callers that
hold a plugin registry can back it with the registered ProcedureMode;
callers without one should use validate_read_only, which treats every
procedure as read-only (AST-determinable writes are still rejected).
ยงErrors
Returns Err(message) describing the first write clause, write subquery, or
write procedure found.