Struct ImageDataDirectory
struct ImageDataDirectory { ... }
Fields
virtual_address: crate::endian::U32<crate::endian::LittleEndian>size: crate::endian::U32<crate::endian::LittleEndian>
Implementations
impl pe::ImageDataDirectory
fn address_range(self: &Self) -> (u32, u32)Return the virtual address range of this directory entry.
fn file_range(self: &Self, sections: &SectionTable<'_>) -> Result<(u32, u32)>Return the file offset and size of this directory entry.
This function has some limitations:
- It requires that the data is contained in a single section.
- It uses the size field of the directory entry, which is not desirable for all data directories.
- It uses the
virtual_addressof the directory entry as an address, which is not valid forIMAGE_DIRECTORY_ENTRY_SECURITY.
fn data<'data, R: ReadRef<'data>>(self: &Self, data: R, sections: &SectionTable<'data>) -> Result<&'data [u8]>Get the data referenced by this directory entry.
This function has some limitations:
- It requires that the data is contained in a single section.
- It uses the size field of the directory entry, which is not desirable for all data directories.
- It uses the
virtual_addressof the directory entry as an address, which is not valid forIMAGE_DIRECTORY_ENTRY_SECURITY.
impl Clone for ImageDataDirectory
fn clone(self: &Self) -> ImageDataDirectory
impl Copy for ImageDataDirectory
impl Debug for ImageDataDirectory
fn fmt(self: &Self, f: &mut $crate::fmt::Formatter<'_>) -> $crate::fmt::Result
impl Freeze for ImageDataDirectory
impl Pod for ImageDataDirectory
impl RefUnwindSafe for ImageDataDirectory
impl Send for ImageDataDirectory
impl Sync for ImageDataDirectory
impl Unpin for ImageDataDirectory
impl UnwindSafe for ImageDataDirectory
impl<T> Any for ImageDataDirectory
fn type_id(self: &Self) -> TypeId
impl<T> Borrow for ImageDataDirectory
fn borrow(self: &Self) -> &T
impl<T> BorrowMut for ImageDataDirectory
fn borrow_mut(self: &mut Self) -> &mut T
impl<T> CloneToUninit for ImageDataDirectory
unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)
impl<T> From for ImageDataDirectory
fn from(t: T) -> TReturns the argument unchanged.
impl<T> ToOwned for ImageDataDirectory
fn to_owned(self: &Self) -> Tfn clone_into(self: &Self, target: &mut T)
impl<T, U> Into for ImageDataDirectory
fn into(self: Self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom for ImageDataDirectory
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
impl<T, U> TryInto for ImageDataDirectory
fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>