Struct garde::validate::Unvalidated
source · #[repr(transparent)]pub struct Unvalidated<T>(_);
Expand description
A struct which wraps a potentially invalid instance of some T
.
Use the validate
method to turn this type into a Valid<T>
.
Implementations§
Trait Implementations§
source§impl<T: Clone> Clone for Unvalidated<T>
impl<T: Clone> Clone for Unvalidated<T>
source§fn clone(&self) -> Unvalidated<T>
fn clone(&self) -> Unvalidated<T>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<T: Debug> Debug for Unvalidated<T>
impl<T: Debug> Debug for Unvalidated<T>
source§impl<T: Default> Default for Unvalidated<T>
impl<T: Default> Default for Unvalidated<T>
source§fn default() -> Unvalidated<T>
fn default() -> Unvalidated<T>
Returns the “default value” for a type. Read more
source§impl<'de, T> Deserialize<'de> for Unvalidated<T>where
T: Deserialize<'de>,
impl<'de, T> Deserialize<'de> for Unvalidated<T>where T: Deserialize<'de>,
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl<T: Validate> From<T> for Unvalidated<T>
impl<T: Validate> From<T> for Unvalidated<T>
impl<T: Copy> Copy for Unvalidated<T>
Auto Trait Implementations§
impl<T> RefUnwindSafe for Unvalidated<T>where T: RefUnwindSafe,
impl<T> Send for Unvalidated<T>where T: Send,
impl<T> Sync for Unvalidated<T>where T: Sync,
impl<T> Unpin for Unvalidated<T>where T: Unpin,
impl<T> UnwindSafe for Unvalidated<T>where T: UnwindSafe,
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