Struct glommio::io::DmaBuffer[][src]

pub struct DmaBuffer { /* fields omitted */ }
Expand description

A buffer suitable for Direct I/O over io_uring

Direct I/O has strict requirements about alignment. On top of that, io_uring places additional restrictions on memory placement if we are to use advanced features like registered buffers.

The DmaBuffer is a buffer that adheres to those properties making it suitable for io_uring’s Direct I/O.

Implementations

Returns a representation of the current addressable contents of this DmaBuffer as a byte slice

Returns a representation of the current addressable contents of this DmaBuffer as a mutable byte slice

Returns the current number of bytes present in the addressable contents of this DmaBuffer

Indicates whether or not this buffer is empty. An empty buffer can be, for instance, the result of a read past the end of a file.

Returns a representation of the current addressable contents of this DmaBuffer as mutable pointer

Returns a representation of the current addressable contents of this DmaBuffer as pointer

Trait Implementations

Performs the conversion.

Performs the conversion.

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

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

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.