Skip to main content

ResourceErrorBuilder

Struct ResourceErrorBuilder 

Source
pub struct ResourceErrorBuilder<Resource, Context> { /* private fields */ }

Implementations§

Source§

impl<Context> ResourceErrorBuilder<ResourceMissing, Context>

Source

pub fn with_resource( self, resource: impl Into<String>, ) -> ResourceErrorBuilder<ResourceSet, Context>

Source§

impl<Context> ResourceErrorBuilder<ResourceOptional, Context>

Source

pub fn with_resource( self, resource: impl Into<String>, ) -> ResourceErrorBuilder<ResourceSet, Context>

Source§

impl<Resource> ResourceErrorBuilder<Resource, NeedsFieldViolation>

Source

pub fn with_field_violation( self, field: impl Into<String>, description: impl Into<String>, reason: impl Into<String>, ) -> ResourceErrorBuilder<Resource, HasFieldViolations>

Source

pub fn with_format( self, message: impl Into<String>, ) -> ResourceErrorBuilder<Resource, HasFormatMessage>

Source

pub fn with_constraint( self, message: impl Into<String>, ) -> ResourceErrorBuilder<Resource, HasConstraintMessage>

Source§

impl<Resource> ResourceErrorBuilder<Resource, HasFieldViolations>

Source

pub fn with_field_violation( self, field: impl Into<String>, description: impl Into<String>, reason: impl Into<String>, ) -> Self

Source§

impl<Resource> ResourceErrorBuilder<Resource, NeedsPreconditionViolation>

Source

pub fn with_precondition_violation( self, subject: impl Into<String>, description: impl Into<String>, type_: impl Into<String>, ) -> ResourceErrorBuilder<Resource, HasPreconditionViolations>

Source§

impl<Resource> ResourceErrorBuilder<Resource, HasPreconditionViolations>

Source

pub fn with_precondition_violation( self, subject: impl Into<String>, description: impl Into<String>, type_: impl Into<String>, ) -> Self

Source§

impl<Resource> ResourceErrorBuilder<Resource, NeedsQuotaViolation>

Source

pub fn with_quota_violation( self, subject: impl Into<String>, description: impl Into<String>, ) -> ResourceErrorBuilder<Resource, HasQuotaViolations>

Source§

impl<Resource> ResourceErrorBuilder<Resource, HasQuotaViolations>

Source

pub fn with_quota_violation( self, subject: impl Into<String>, description: impl Into<String>, ) -> Self

Source§

impl<Resource> ResourceErrorBuilder<Resource, NeedsReason>

Source

pub fn with_reason( self, reason: impl Into<String>, ) -> ResourceErrorBuilder<Resource, HasReason>

Source§

impl<Resource, Context> ResourceErrorBuilder<Resource, Context>
where Resource: ResourceResolved, Context: ContextResolved,

Auto Trait Implementations§

§

impl<Resource, Context> Freeze for ResourceErrorBuilder<Resource, Context>
where Resource: Freeze, Context: Freeze,

§

impl<Resource, Context> RefUnwindSafe for ResourceErrorBuilder<Resource, Context>
where Resource: RefUnwindSafe, Context: RefUnwindSafe,

§

impl<Resource, Context> Send for ResourceErrorBuilder<Resource, Context>
where Resource: Send, Context: Send,

§

impl<Resource, Context> Sync for ResourceErrorBuilder<Resource, Context>
where Resource: Sync, Context: Sync,

§

impl<Resource, Context> Unpin for ResourceErrorBuilder<Resource, Context>
where Resource: Unpin, Context: Unpin,

§

impl<Resource, Context> UnsafeUnpin for ResourceErrorBuilder<Resource, Context>
where Resource: UnsafeUnpin, Context: UnsafeUnpin,

§

impl<Resource, Context> UnwindSafe for ResourceErrorBuilder<Resource, Context>
where Resource: UnwindSafe, Context: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.