Enum build_script::value::Value
source ·
[−]pub enum Value {
Singular(String),
Mapping(String, String),
OptionalKey(Option<String>, String),
UnquotedOptionalKey(Option<String>, String),
OptionalValue(String, Option<String>),
UnquotedOptionalValue(String, Option<String>),
UnquotedMapping(String, String),
}
Expand description
The value of an Instruction
.
Variants
Singular(String)
Tuple Fields
0: String
A singular value.
Mapping(String, String)
A mapping (2 values).
OptionalKey(Option<String>, String)
A mapping with an optional key.
UnquotedOptionalKey(Option<String>, String)
A mapping with an optional key. Once printed, the value won’t have quotes.
OptionalValue(String, Option<String>)
A mapping with an optional value.
UnquotedOptionalValue(String, Option<String>)
A mapping with an optional value. Once printed, if the value exists, the value won’t have quotes.
UnquotedMapping(String, String)
A mapping with the value not having quotes.
Implementations
Returns true
if the value is a Singular
value.
Returns true
if the value is a Mapping
value.
Returns true
if the value is an OptionalKey
value.
Returns true
if the value is an UnquotedOptionalKey
value.
Returns true
if the value is an OptionalValue
value.
Returns true
if the value is an UnquotedOptionalValue
value.
Returns true
if the value is an UnquotedMapping
value.
Trait Implementations
This method returns an ordering between self
and other
values if one exists. Read more
This method tests less than (for self
and other
) and is used by the <
operator. Read more
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
Auto Trait Implementations
impl RefUnwindSafe for Value
impl UnwindSafe for Value
Blanket Implementations
Mutably borrows from an owned value. Read more