pub trait AuthorizationContext<DM, SC, TC> {
    type Context<'a>: Send + Sync
       where Self: 'a;
    type Subject<'a>: Send + Sync
       where Self: 'a;

    // Required methods
    fn context(&self) -> Self::Context<'_>;
    fn subject(&self) -> Self::Subject<'_>;
    fn decision_maker(&self) -> &DM;
    fn storage_client(&self) -> &SC;
    fn transaction_cache(&self) -> &TC;
}
Expand description

Wraps all components of an action requiring authorization which can be expected to be carried around in an application context.

Required Associated Types§

source

type Context<'a>: Send + Sync where Self: 'a

decision context

source

type Subject<'a>: Send + Sync where Self: 'a

decision subject

Required Methods§

source

fn context(&self) -> Self::Context<'_>

source

fn subject(&self) -> Self::Subject<'_>

source

fn decision_maker(&self) -> &DM

source

fn storage_client(&self) -> &SC

source

fn transaction_cache(&self) -> &TC

Implementors§