pub enum Kind {
Bool,
Int {
min: i64,
max: i64,
},
Enum {
choices: Vec<String>,
},
String {
non_empty: bool,
},
Url,
Path,
SocketAddr,
List {
item: Box<Kind>,
},
Secret,
}Expand description
The type of a setting’s value, and so what it accepts.
Variants§
Bool
true/false, also written on/off.
Int
An integer within min..=max.
Enum
One of a fixed set of strings.
String
Free text.
Url
An http or https URL.
Path
A filesystem path.
SocketAddr
A host:port socket address.
List
A list of items of one kind.
Secret
A credential: device-scope, never read back, never taken from text on a command line.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Kind
impl<'de> Deserialize<'de> for Kind
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
impl StructuralPartialEq for Kind
Auto Trait Implementations§
impl Freeze for Kind
impl RefUnwindSafe for Kind
impl Send for Kind
impl Sync for Kind
impl Unpin for Kind
impl UnsafeUnpin for Kind
impl UnwindSafe for Kind
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