Struct runestick::Range[][src]

pub struct Range {
    pub start: Option<Value>,
    pub end: Option<Value>,
    pub limits: RangeLimits,
}
Expand description

Struct representing a dynamic anonymous object.

Examples

use runestick::{Range, RangeLimits, ToValue as _};

let from = 42i64.to_value()?;
let _ = Range::new(Some(from), None, RangeLimits::HalfOpen);

Fields

start: Option<Value>

The start value of the range.

end: Option<Value>

The to value of the range.

limits: RangeLimits

The limits of the range.

Implementations

Construct a new range.

Coerce range into an iterator.

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.

Try to convert to the given type, from the given value.

Hook to install more things into the module.

The generic name of the named thing.

The exact type name

Convert into a value.

Convert into a type hash.

Access diagnostical information on the value type.

The output type from the unsafe coercion.

The raw guard returned. Read more

Convert the given reference using unsafe assumptions to a value. Read more

Coerce the output of an unsafe from value into the final output type. Read more

The output type from the unsafe coercion.

The raw guard returned. Read more

Convert the given reference using unsafe assumptions to a value. Read more

Coerce the output of an unsafe from value into the final output type. 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

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.