Struct nu_protocol::value::Value[][src]

pub struct Value {
    pub value: UntaggedValue,
    pub tag: Tag,
}
Expand description

The fundamental structured value that flows through the pipeline, with associated metadata

Fields

value: UntaggedValuetag: Tag

Implementations

Helper to create a Value

Get the corresponding anchor (originating location) for the Value

Get the name (url, filepath, etc) behind an anchor for the Value

Get the metadata for the Value

View the Value as a string, if possible

View the Value as a FilePath (PathBuf), if possible

View the Value as a Int, if possible

View the Value as a Int, if possible

View the Value as a Filesize (u64), if possible

View the Value as a Duration (BigInt), if possible

View the Value as a Decimal (BigDecimal), if possible

View a Primitive::Binary as a Vec, if possible

View into the borrowed string contents of a Value, if possible

View the Value as a path, if possible

View the Value as a Primitive value, if possible

View the Value as a Primitive value, if possible

View the Value as char, if possible

View the Value as unsigned size, if possible

View the Value as unsigned 64-bit, if possible

View the Value as signed 64-bit, if possible

View the Value as unsigned 32-bit, if possible

View the Value as signed 32-bit, if possible

View the Value as signed 16-bit, if possible

View the Value as signed 32-bit float, if possible

View the Value as signed 64-bit float, if possible

View the Value as boolean, if possible

Returns an iterator of the values rows

Returns an iterator of the value’s cells

Returns true if the value is empty

Methods from Deref<Target = UntaggedValue>

Get the corresponding descriptors (column names) associated with this value

Returns true if this value represents a binary

Returns true if this value represents boolean true

Returns true if this value represents a filesize

Returns true if this value represents a duration

Returns true if this value represents a table

Returns true if this value represents a row

Returns true if this value represents a string

Returns true if the value represents something other than Nothing

Returns true if the value represents Nothing

Returns true if the value represents an error

Expect this value to be an error and return it

Expect this value to be a string and return it

Expect this value to be an integer and return it

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

Overload deferencing to give back the UntaggedValue inside of a Value

The resulting type after dereferencing.

Dereferences the value.

Deserialize this value from the given Serde deserializer. Read more

Performs the conversion.

Convert a borrowed Value into a borrowed UntaggedValue

Performs the conversion.

Performs the conversion.

Convert a builder into a tagged Value

Convert an UntaggedValue into a Value with a default tag

Performs the conversion.

Convert a Value into an UntaggedValue

Performs the conversion.

Return the corresponding Span for the Value

Feeds this value into the given Hasher. Read more

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

This method returns an Ordering between self and other. Read more

Compares and returns the maximum of two values. Read more

Compares and returns the minimum of two values. Read more

Restrict a value to a certain interval. Read more

Test a dictionary against a Value for equality

This method tests for !=.

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

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

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

Get a borrowed Value ready to be pretty-printed

A convenience method that prints out the document without colors in 70 columns. Generally, you should use plain_string or colored_string if possible, but display() can be useful for trace lines and things like that, where you don’t have control over the terminal. Read more

Get a Value ready to be pretty-printed

A convenience method that prints out the document without colors in 70 columns. Generally, you should use plain_string or colored_string if possible, but display() can be useful for trace lines and things like that, where you don’t have control over the terminal. Read more

Serialize this value into the given Serde serializer. Read more

Get the type name for the Value

Convert to an i64 integer, if possible

The type returned in the event of a conversion error.

Convert to a string, if possible

The type returned in the event of a conversion error.

Convert to a u8 vec, if possible

The type returned in the event of a conversion error.

Convert to a dictionary, if possible

The type returned in the event of a conversion error.

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

Compare self to key and return true if they are equal.

Performs the conversion.

Performs the conversion.

Converts a value into a Spanned value

Converts a value into a Spanned value, using an unknown Span

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.