pub struct Struct { /* private fields */ }
Expand description

Defines a struct.

Implementations

Return a structure definition with the provided name

Returns a reference to the type

Set the structure visibility.

Add a generic to the struct.

Add a where bound to the struct.

Set the structure documentation.

Add a new type that the struct should derive.

Add a new attribute to the struct

Specify lint attribute to supress a warning or error.

Specify representation.

Add an arbitrary macro.

Push a named field to the struct.

A struct can either set named fields with this function or tuple fields with push_tuple_field, but not both.

Add a named field to the struct.

A struct can either set named fields with this function or tuple fields with tuple_field, but not both.

Create a named field for the struct.

A struct can either set named fields with this function or tuple fields with tuple_field, but not both.

Add a tuple field to the struct.

A struct can either set tuple fields with this function or named fields with field, but not both.

Formats the struct using the given formatter.

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

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.