[][src]Struct falcon::memory::backing::Memory

pub struct Memory { /* fields omitted */ }

A simple memory model, containing permissioned sections of type u8.

Methods

impl Memory[src]

pub fn new(endian: Endian) -> Memory[src]

Create a new backed memory module with the given endianness.

pub fn sections(&self) -> &BTreeMap<u64, Section>[src]

Get the sections in this memory module.

pub fn permissions(&self, address: u64) -> Option<MemoryPermissions>[src]

Get the permissions at the given address.

pub fn get8(&self, address: u64) -> Option<u8>[src]

Get the u8 value at the given address.

pub fn set32(&mut self, address: u64, value: u32) -> Result<()>[src]

Set the 32-bit value at the given address, allowing the memory model to account for the underlying endianness.

pub fn get32(&self, address: u64) -> Option<u32>[src]

Get the 32-bit value at the given address, allowing the memory model to account for the underlying endianness.

pub fn get(&self, address: u64, bits: usize) -> Option<Constant>[src]

Get a constant value up to a certain number of bits

pub fn set_memory(
    &mut self,
    address: u64,
    data: Vec<u8>,
    permissions: MemoryPermissions
)
[src]

Set the memory at the given address, and give that memory the given permissions.

This takes care of the underlying memory sections automatically.

Trait Implementations

impl Clone for Memory[src]

impl Debug for Memory[src]

impl<'de> Deserialize<'de> for Memory[src]

impl Eq for Memory[src]

impl PartialEq<Memory> for Memory[src]

impl Serialize for Memory[src]

impl StructuralEq for Memory[src]

impl StructuralPartialEq for Memory[src]

impl TranslationMemory for Memory[src]

Auto Trait Implementations

impl RefUnwindSafe for Memory

impl Send for Memory

impl Sync for Memory

impl Unpin for Memory

impl UnwindSafe for Memory

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.