pub enum Detail {
    Bool {
        bit: u8,
    },
    Num,
    Enum {
        last: u8,
        enumerators: u16,
    },
    Preset,
}
Expand description

The different kind of settings along with descriptor bits that depend on the kind.

Variants

Bool

Fields

bit: u8

0-7.

A boolean setting only uses one bit, numbered from LSB.

Num

A numerical setting uses the whole byte.

Enum

Fields

last: u8

Numerical value of last enumerator, allowing for 1-256 enumerators.

enumerators: u16

First enumerator in the ENUMERATORS table.

An Enum setting uses a range of enumerators.

Preset

A preset is not an individual setting, it is a collection of settings applied at once.

The Descriptor::offset field refers to the PRESETS table.

Implementations

Check if a detail is a Detail::Preset. Useful because the Descriptor offset field has a different meaning when the detail is a preset.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Feeds this value into the given Hasher. Read more

Feeds a slice of this type into the given Hasher. Read more

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

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.

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

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.