pub struct Denied {
pub object: Option<Cow<'static, str>>,
pub action: Option<Cow<'static, str>>,
/* private fields */
}Expand description
Authorization failure. Never retried, always audited.
Fields§
§object: Option<Cow<'static, str>>§action: Option<Cow<'static, str>>Implementations§
Source§impl Denied
impl Denied
pub fn new() -> Self
pub fn from_error(e: impl Error + Send + Sync + 'static) -> Self
pub fn with_object(self, object: impl Into<Cow<'static, str>>) -> Self
pub fn with_action(self, action: impl Into<Cow<'static, str>>) -> Self
pub fn with_source(self, e: impl Error + Send + Sync + 'static) -> Self
pub fn with_context(self, c: impl Into<Cow<'static, str>>) -> Self
pub fn context(&self) -> Option<&str>
pub fn source_arc(&self) -> Option<&Arc<dyn Error + Send + Sync>>
Trait Implementations§
Source§impl Error for Denied
impl Error for Denied
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for Denied
impl !UnwindSafe for Denied
impl Freeze for Denied
impl Send for Denied
impl Sync for Denied
impl Unpin for Denied
impl UnsafeUnpin for Denied
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more