pub enum PhraseRefusal {
Empty,
NotPrintableAscii {
byte: u8,
at: usize,
},
Ms1Shaped,
TooLong {
chars: usize,
},
Hex64,
}Expand description
Why a phrase was refused. One variant per rule, in the order the rule checks them; the CALLER renders the sentence.
Variants§
Empty
No bytes at all.
NotPrintableAscii
A byte outside 0x20..=0x7E, with the byte and its position.
Ms1Shaped
An ms1 string — a preimage plate, not a phrase.
TooLong
Over HASHLOCK_PHRASE_MAX_CHARS.
Hex64
Exactly 64 hex characters — a preimage in hex, not a phrase.
Trait Implementations§
Source§impl Clone for PhraseRefusal
impl Clone for PhraseRefusal
Source§fn clone(&self) -> PhraseRefusal
fn clone(&self) -> PhraseRefusal
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for PhraseRefusal
Source§impl Debug for PhraseRefusal
impl Debug for PhraseRefusal
impl Eq for PhraseRefusal
Source§impl PartialEq for PhraseRefusal
impl PartialEq for PhraseRefusal
impl StructuralPartialEq for PhraseRefusal
Auto Trait Implementations§
impl Freeze for PhraseRefusal
impl RefUnwindSafe for PhraseRefusal
impl Send for PhraseRefusal
impl Sync for PhraseRefusal
impl Unpin for PhraseRefusal
impl UnsafeUnpin for PhraseRefusal
impl UnwindSafe for PhraseRefusal
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