pub trait PolicyClient:
Send
+ Sync
+ 'static {
// Required method
fn evaluate<'a>(
&'a self,
path: &'a str,
input: JsonValue,
) -> BoxFuture<'a, Result<JsonValue, PolicyError>>;
}Expand description
Evaluates policies: a path and a JSON input in, a raw decision document out.
The raw document is normalized by
PolicyDecision::normalize (approval)
or parse_allowlist (capabilities). Clients
return JsonValue::Null when the policy produced no value (an undefined
rule), never an error.
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".