pub struct Secret<T> { /* private fields */ }Expand description
No Display and no Serialize, so no reply, log field or event payload can carry it.
Implementations§
Trait Implementations§
Source§impl<T: Cast> Cast for Secret<T>
impl<T: Cast> Cast for Secret<T>
const COLUMNS: &'static [ColumnSpec] = T::COLUMNS
const NULLABLE: bool = T::NULLABLE
Source§const SENSITIVE: bool = true
const SENSITIVE: bool = true
A field holding it is never filtered, sorted, listed or searched, as
#[sensitive] ones.fn encode(&self, out: &mut Vec<SqlValue>)
fn decode(row: &mut dyn ColumnReader) -> Result<Self>
Source§const MOVES: Option<fn(&Self) -> Option<&'static Targets>> = None
const MOVES: Option<fn(&Self) -> Option<&'static Targets>> = None
Set for a value moving between listed states; a save of any other value skips the check.
Source§const HOLDS_STATES: bool
const HOLDS_STATES: bool
Set when a state anywhere in the value is checked on save, as a field’s of several.
fn refuse_unlisted_move( field: &str, stored: &Self, current: &Self, ) -> Result<(), Error>
Source§impl<'de, T: Deserialize<'de>> Deserialize<'de> for Secret<T>
impl<'de, T: Deserialize<'de>> Deserialize<'de> for Secret<T>
Source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserialize this value from the given Serde deserializer. Read more
impl<T: AsRef<[u8]>> Eq for Secret<T>
Auto Trait Implementations§
impl<T> Forget for Secret<T>
impl<T> Freeze for Secret<T>where
T: Freeze,
impl<T> RefUnwindSafe for Secret<T>where
T: RefUnwindSafe,
impl<T> Send for Secret<T>where
T: Send,
impl<T> Sync for Secret<T>where
T: Sync,
impl<T> Unpin for Secret<T>where
T: Unpin,
impl<T> UnsafeUnpin for Secret<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for Secret<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