pub struct ProgramSegmentFlags(/* private fields */);
Expand description
Permissions and other OS/arch-specific flags for individual program segments.
Implementations§
Source§impl ProgramSegmentFlags
impl ProgramSegmentFlags
Sourcepub fn execute(&self) -> bool
pub fn execute(&self) -> bool
Indicates the segment contains code that should be executable by the process.
Sourcepub fn write(&self) -> bool
pub fn write(&self) -> bool
Indicates the segment contains data that should be writable by the process.
Sourcepub fn read(&self) -> bool
pub fn read(&self) -> bool
Indicates the segment contains data that should be readable by the process.
Sourcepub fn os_defined(&self) -> u8
pub fn os_defined(&self) -> u8
Bits that are left for OS-specific flags.
Sourcepub fn arch_defined(&self) -> u8
pub fn arch_defined(&self) -> u8
Bits that are left for CPU architecture-specific flags.
Sourcepub fn set_execute(&mut self, value: bool)
pub fn set_execute(&mut self, value: bool)
Indicates the segment contains code that should be executable by the process.
Sourcepub fn with_execute(&mut self, value: bool) -> Self
pub fn with_execute(&mut self, value: bool) -> Self
Indicates the segment contains code that should be executable by the process.
Sourcepub fn set_write(&mut self, value: bool)
pub fn set_write(&mut self, value: bool)
Indicates the segment contains data that should be writable by the process.
Sourcepub fn with_write(&mut self, value: bool) -> Self
pub fn with_write(&mut self, value: bool) -> Self
Indicates the segment contains data that should be writable by the process.
Sourcepub fn set_read(&mut self, value: bool)
pub fn set_read(&mut self, value: bool)
Indicates the segment contains data that should be readable by the process.
Sourcepub fn with_read(&mut self, value: bool) -> Self
pub fn with_read(&mut self, value: bool) -> Self
Indicates the segment contains data that should be readable by the process.
Sourcepub fn set_os_defined(&mut self, value: u8)
pub fn set_os_defined(&mut self, value: u8)
Bits that are left for OS-specific flags.
Sourcepub fn with_os_defined(&self, value: u8) -> Self
pub fn with_os_defined(&self, value: u8) -> Self
Bits that are left for OS-specific flags.
Sourcepub fn set_arch_defined(&mut self, value: u8)
pub fn set_arch_defined(&mut self, value: u8)
Bits that are left for CPU architecture-specific flags.
Sourcepub fn with_arch_defined(&self, value: u8) -> Self
pub fn with_arch_defined(&self, value: u8) -> Self
Bits that are left for CPU architecture-specific flags.
Trait Implementations§
Source§impl Bitfield<u32> for ProgramSegmentFlags
impl Bitfield<u32> for ProgramSegmentFlags
Source§impl Clone for ProgramSegmentFlags
impl Clone for ProgramSegmentFlags
Source§fn clone(&self) -> ProgramSegmentFlags
fn clone(&self) -> ProgramSegmentFlags
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more