pub struct MmapRegionBuilder<B = ()> { /* private fields */ }
Expand description

A factory struct to build MmapRegion objects.

Implementations

Create a new MmapRegionBuilder using the default value for the inner Bitmap object.

Create a new MmapRegionBuilder using the provided Bitmap object.

When instantiating the builder for a region that does not require dirty bitmap bitmap tracking functionality, we can specify a trivial Bitmap implementation such as ().

Create the MmapRegion object with the specified mmap memory protection flag prot.

Create the MmapRegion object with the specified mmap flags.

Create the MmapRegion object with the specified file_offset.

Create the MmapRegion object with the specified hugetlbfs flag.

Create the MmapRegion object with pre-mmapped raw pointer.

Safety

To use this safely, the caller must guarantee that raw_addr and self.size define a region within a valid mapping that is already present in the process.

Build the MmapRegion object.

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 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.