Struct elfkit::types::HeaderFlags
[−]
pub struct HeaderFlags { /* fields omitted */ }
Methods
impl HeaderFlags
const MIPS_NOREORDER: HeaderFlags
MIPS_NOREORDER: HeaderFlags = HeaderFlags{bits: 1,}
at least one .noreorder directive in an assembly language source contributes to the object module
const MIPS_PIC: HeaderFlags
MIPS_PIC: HeaderFlags = HeaderFlags{bits: 2,}
the file contains position-independent code that can be relocated in memory.
const MIPS_CPIC: HeaderFlags
MIPS_CPIC: HeaderFlags = HeaderFlags{bits: 4,}
the file contains code that follows standard calling sequence rules for calling position-independent code. The code in this file is not necessarily position independent. The EF_MIPS_PIC and EF_MIPS_CPIC flags must be mutually exclusive
const MIPS_ARCH: HeaderFlags
MIPS_ARCH: HeaderFlags = HeaderFlags{bits: 4026531840,}
extensions to the basic MIPS I architecture. (from the original doc, but this doesn't appear to be used)
const MIPS_ARCH_32: HeaderFlags
MIPS_ARCH_32: HeaderFlags = HeaderFlags{bits: 1342177280,}
const MIPS_ARCH_64: HeaderFlags
MIPS_ARCH_64: HeaderFlags = HeaderFlags{bits: 1610612736,}
const MIPS_ARCH_32R2: HeaderFlags
MIPS_ARCH_32R2: HeaderFlags = HeaderFlags{bits: 1879048192,}
const MIPS_ARCH_64R2: HeaderFlags
MIPS_ARCH_64R2: HeaderFlags = HeaderFlags{bits: 2147483648,}
const MIPS_ABI_O32: HeaderFlags
MIPS_ABI_O32: HeaderFlags = HeaderFlags{bits: 4096,}
original 32bit abi, this appears to be a GNU specific flag
const MIPS_ABI_O64: HeaderFlags
MIPS_ABI_O64: HeaderFlags = HeaderFlags{bits: 8192,}
the o32 abi made 64 by some undocumented gnu stuff (i sincerely hope this isn't in use)
const ARM_EABI_VER1: HeaderFlags
ARM_EABI_VER1: HeaderFlags = HeaderFlags{bits: 16777216,}
const ARM_EABI_VER2: HeaderFlags
ARM_EABI_VER2: HeaderFlags = HeaderFlags{bits: 33554432,}
const ARM_EABI_VER3: HeaderFlags
ARM_EABI_VER3: HeaderFlags = HeaderFlags{bits: 50331648,}
const ARM_EABI_VER4: HeaderFlags
ARM_EABI_VER4: HeaderFlags = HeaderFlags{bits: 67108864,}
const ARM_EABI_VER5: HeaderFlags
ARM_EABI_VER5: HeaderFlags = HeaderFlags{bits: 83886080,}
const ARM_ABI_FLOAT_HARD: HeaderFlags
ARM_ABI_FLOAT_HARD: HeaderFlags = HeaderFlags{bits: 1024,}
const ARM_ABI_FLOAT_SOFT: HeaderFlags
ARM_ABI_FLOAT_SOFT: HeaderFlags = HeaderFlags{bits: 512,}
fn empty() -> HeaderFlags
Returns an empty set of flags.
fn all() -> HeaderFlags
Returns the set containing all flags.
fn bits(&self) -> u32
Returns the raw value of the flags currently stored.
fn from_bits(bits: u32) -> Option<HeaderFlags>
Convert from underlying bit representation, unless that representation contains bits that do not correspond to a flag.
fn from_bits_truncate(bits: u32) -> HeaderFlags
Convert from underlying bit representation, dropping any bits that do not correspond to flags.
fn is_empty(&self) -> bool
Returns true
if no flags are currently stored.
fn is_all(&self) -> bool
Returns true
if all flags are currently set.
fn intersects(&self, other: HeaderFlags) -> bool
Returns true
if there are flags common to both self
and other
.
fn contains(&self, other: HeaderFlags) -> bool
Returns true
all of the flags in other
are contained within self
.
fn insert(&mut self, other: HeaderFlags)
Inserts the specified flags in-place.
fn remove(&mut self, other: HeaderFlags)
Removes the specified flags in-place.
fn toggle(&mut self, other: HeaderFlags)
Toggles the specified flags in-place.
fn set(&mut self, other: HeaderFlags, value: bool)
Inserts or removes the specified flags depending on the passed value.
Trait Implementations
impl Copy for HeaderFlags
impl PartialEq for HeaderFlags
fn eq(&self, __arg_0: &HeaderFlags) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &HeaderFlags) -> bool
This method tests for !=
.
impl Eq for HeaderFlags
impl Clone for HeaderFlags
fn clone(&self) -> HeaderFlags
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl PartialOrd for HeaderFlags
fn partial_cmp(&self, __arg_0: &HeaderFlags) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, __arg_0: &HeaderFlags) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, __arg_0: &HeaderFlags) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, __arg_0: &HeaderFlags) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, __arg_0: &HeaderFlags) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Ord for HeaderFlags
fn cmp(&self, __arg_0: &HeaderFlags) -> Ordering
This method returns an Ordering
between self
and other
. Read more
fn max(self, other: Self) -> Self
[src]
ord_max_min
)Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
[src]
ord_max_min
)Compares and returns the minimum of two values. Read more
impl Hash for HeaderFlags
fn hash<__H: Hasher>(&self, __arg_0: &mut __H)
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl Default for HeaderFlags
[src]
fn default() -> HeaderFlags
[src]
Returns the "default value" for a type. Read more
impl Debug for HeaderFlags
impl Binary for HeaderFlags
impl Octal for HeaderFlags
impl LowerHex for HeaderFlags
impl UpperHex for HeaderFlags
impl BitOr for HeaderFlags
type Output = HeaderFlags
The resulting type after applying the |
operator.
fn bitor(self, other: HeaderFlags) -> HeaderFlags
Returns the union of the two sets of flags.
impl BitOrAssign for HeaderFlags
fn bitor_assign(&mut self, other: HeaderFlags)
Adds the set of flags.
impl BitXor for HeaderFlags
type Output = HeaderFlags
The resulting type after applying the ^
operator.
fn bitxor(self, other: HeaderFlags) -> HeaderFlags
Returns the left flags, but with all the right flags toggled.
impl BitXorAssign for HeaderFlags
fn bitxor_assign(&mut self, other: HeaderFlags)
Toggles the set of flags.
impl BitAnd for HeaderFlags
type Output = HeaderFlags
The resulting type after applying the &
operator.
fn bitand(self, other: HeaderFlags) -> HeaderFlags
Returns the intersection between the two sets of flags.
impl BitAndAssign for HeaderFlags
fn bitand_assign(&mut self, other: HeaderFlags)
Disables all flags disabled in the set.
impl Sub for HeaderFlags
type Output = HeaderFlags
The resulting type after applying the -
operator.
fn sub(self, other: HeaderFlags) -> HeaderFlags
Returns the set difference of the two sets of flags.
impl SubAssign for HeaderFlags
fn sub_assign(&mut self, other: HeaderFlags)
Disables all flags enabled in the set.
impl Not for HeaderFlags
type Output = HeaderFlags
The resulting type after applying the !
operator.
fn not(self) -> HeaderFlags
Returns the complement of this set of flags.
impl Extend<HeaderFlags> for HeaderFlags
fn extend<T: IntoIterator<Item = HeaderFlags>>(&mut self, iterator: T)
Extends a collection with the contents of an iterator. Read more
impl FromIterator<HeaderFlags> for HeaderFlags
fn from_iter<T: IntoIterator<Item = HeaderFlags>>(iterator: T) -> HeaderFlags
Creates a value from an iterator. Read more