Struct oxide_auth::code_grant::backend::GuardRef
[−]
[src]
pub struct GuardRef<'a> { /* fields omitted */ }
Methods
impl<'a> GuardRef<'a>[src]
fn protect<'r>(&self, req: &'r GuardRequest) -> Result<(), AccessError> where
'a: 'r, [src]
'a: 'r,
fn with<S>(issuer: &'a mut Issuer, scopes: &'a S) -> Self where
S: AsRef<[Scope]>, [src]
S: AsRef<[Scope]>,
Construct a guard from an issuer backend and a choice of scopes. A grant need only have ONE of the scopes to access the resource but each scope can require multiple subscopes.