pub struct VirtualMapping {
pub start: VirtualAddress,
pub size: usize,
pub mapping_type: MappingType,
pub flags: PageFlags,
pub physical_frames: Vec<FrameNumber>,
}Expand description
Virtual memory mapping
Fields§
§start: VirtualAddressStart address
size: usizeSize in bytes
mapping_type: MappingTypeMapping type
flags: PageFlagsPage flags
physical_frames: Vec<FrameNumber>Backing physical frames (if mapped)
Implementations§
Source§impl VirtualMapping
impl VirtualMapping
Sourcepub fn new(
start: VirtualAddress,
size: usize,
mapping_type: MappingType,
) -> Self
pub fn new( start: VirtualAddress, size: usize, mapping_type: MappingType, ) -> Self
Create a new virtual mapping
Sourcepub fn contains(&self, addr: VirtualAddress) -> bool
pub fn contains(&self, addr: VirtualAddress) -> bool
Check if address is within this mapping
Sourcepub fn end(&self) -> VirtualAddress
pub fn end(&self) -> VirtualAddress
Get end address
Trait Implementations§
Source§impl Clone for VirtualMapping
impl Clone for VirtualMapping
Source§fn clone(&self) -> VirtualMapping
fn clone(&self) -> VirtualMapping
Returns a duplicate of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for VirtualMapping
impl RefUnwindSafe for VirtualMapping
impl Send for VirtualMapping
impl Sync for VirtualMapping
impl Unpin for VirtualMapping
impl UnwindSafe for VirtualMapping
Blanket Implementations§
§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)