Enum libreda_db::property_storage::PropertyValue[][src]

pub enum PropertyValue {
    String(RcString),
    Bytes(Vec<u8>),
    SInt(i32),
    UInt(u32),
    Float(f64),
}
Expand description

Property value type. Properties can hold different types that are encapsulated in this enum.

Variants

String(RcString)

Property is a string.

Tuple Fields of String

0: RcString
Bytes(Vec<u8>)

Property is a byte string.

Tuple Fields of Bytes

0: Vec<u8>
SInt(i32)

Property is a signed integer.

Tuple Fields of SInt

0: i32
UInt(u32)

Property is an unsigned integer.

Tuple Fields of UInt

0: u32
Float(f64)

Property is a float.

Tuple Fields of Float

0: f64

Implementations

Try to get a string value.

Try to get a &str value. Works for String property values.

Try to get a byte string value.

Try to get a float value.

Try to get an i32 value.

Try to get an i32 value.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.