Struct tarantool::space::Builder

source ·
pub struct Builder<'a> { /* private fields */ }

Implementations§

Add a field to the space’s format.

Use this method to set each field individually or use format to set fields in bulk. The difference is purely syntactical.

Add fields to the space’s format.

Use this method to set fields in bulk or use field to set each field individually. The difference is purely syntactical.

use tarantool::space::{Space, FieldType as FT, IsNullable};

let space = Space::builder("user_names")
    .format([
        ("id", FT::Unsigned),
        ("name", FT::String),
    ])
    .field(("nickname", FT::String, IsNullable::Nullable))
    .create();

Destructure the builder struct into a tuple of name and space options.

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.

Should always be Self
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.