pub struct MemoryMap { /* private fields */ }
Implementations§
source§impl MemoryMap
impl MemoryMap
pub fn new(view: Ref<BinaryView>) -> Self
sourcepub fn base_description(&self) -> String
pub fn base_description(&self) -> String
JSON string representation of the base MemoryMap
, consisting of unresolved auto and user segments.
sourcepub fn description(&self) -> String
pub fn description(&self) -> String
JSON string representation of the MemoryMap
.
pub fn set_logical_enabled(&mut self, enabled: bool)
sourcepub fn is_activated(&self) -> bool
pub fn is_activated(&self) -> bool
Whether the memory map is activated for the associated view.
pub fn add_binary_memory_region( &mut self, name: &str, start: u64, view: &BinaryView, segment_flags: Option<SegmentFlags>, ) -> bool
sourcepub fn add_data_memory_region(
&mut self,
name: &str,
start: u64,
data: &DataBuffer,
segment_flags: Option<SegmentFlags>,
) -> bool
pub fn add_data_memory_region( &mut self, name: &str, start: u64, data: &DataBuffer, segment_flags: Option<SegmentFlags>, ) -> bool
Adds the memory region using a DataBuffer
.
This will add the contents of the DataBuffer
to the database.
sourcepub fn add_remote_memory_region<A: Accessor>(
&mut self,
name: &str,
start: u64,
accessor: &mut FileAccessor<A>,
segment_flags: Option<SegmentFlags>,
) -> bool
pub fn add_remote_memory_region<A: Accessor>( &mut self, name: &str, start: u64, accessor: &mut FileAccessor<A>, segment_flags: Option<SegmentFlags>, ) -> bool
Adds the memory region using a FileAccessor
.
This does not add the region contents to the database, instead accesses to the contents
are done “remotely” to a FileAccessor
.
NOTE: The FileAccessor
MUST live as long as the region is available, currently there is no gurentee by
the type checker that the file accessor is tied to that of the memory region.
pub fn remove_memory_region(&mut self, name: &str) -> bool
pub fn active_memory_region_at(&self, addr: u64) -> String
pub fn memory_region_flags(&self, name: &str) -> SegmentFlags
pub fn set_memory_region_flags( &mut self, name: &str, flags: SegmentFlags, ) -> bool
pub fn is_memory_region_enabled(&self, name: &str) -> bool
pub fn set_memory_region_enabled(&mut self, name: &str, enabled: bool) -> bool
pub fn is_memory_region_rebaseable(&self, name: &str) -> bool
pub fn set_memory_region_rebaseable( &mut self, name: &str, enabled: bool, ) -> bool
pub fn memory_region_fill(&self, name: &str) -> u8
pub fn set_memory_region_fill(&mut self, name: &str, fill: u8) -> bool
pub fn reset(&mut self)
Trait Implementations§
impl Eq for MemoryMap
impl StructuralPartialEq for MemoryMap
Auto Trait Implementations§
impl Freeze for MemoryMap
impl RefUnwindSafe for MemoryMap
impl Send for MemoryMap
impl Sync for MemoryMap
impl Unpin for MemoryMap
impl UnwindSafe for MemoryMap
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more