pub struct ArrayVec<T, const N: usize> { /* private fields */ }
Expand description

Small on-stack vector of max lenth N.

Implementations§

Returns the number of elements in the vector, also referred to as its ‘length’.

Returns true if the vector contains no elements.

Appends an element to the back of a collection.

Safety

The following must be true:

  • The length of this vector is less than N.

Returns the inner data without dropping its elements.

Safety

The caller is responsible for calling the destructor for len initialized items in the returned array.

Trait Implementations§

Converts this type into a shared reference of the (usually inferred) input type.
Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Returns the “default value” for a type. Read more
Executes the destructor for this 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

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
Encode the hex strict representing self into the result. Lower case letters are used (e.g. f9b4ca)
Encode the hex strict representing self into the result. Upper case letters are used (e.g. F9B4CA)
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.