Skip to main content

LysPolicySource

Trait LysPolicySource 

Source
pub trait LysPolicySource {
    type Snapshot;
    type Error: Error;

    // Required method
    fn read_policy(
        &self,
        resource: &AccessResource,
    ) -> Result<Self::Snapshot, Self::Error>;
}
Expand description

Read-only policy source; budget and stop policy remains authority-owned.

The concrete policy representation belongs to the shared authority adapter. No local policy setter or budget decision is provided.

Required Associated Types§

Source

type Snapshot

Native policy snapshot, without a product-side replacement shape.

Source

type Error: Error

Original typed policy read failure.

Required Methods§

Source

fn read_policy( &self, resource: &AccessResource, ) -> Result<Self::Snapshot, Self::Error>

Reads policy for an exact authority resource.

§Errors

Preserves the authority’s typed read or availability failure.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§