#[repr(transparent)]pub struct INPUT_CONTEXT_ID_SE_CEnum(pub u32);
Expand description
Auto-generated FFI type for INPUT_CONTEXT_ID_SE
.
§When use this?
C’s enum is really just a number and there is no guarantee that it will fit within the enum. Therefore, it is used for the following cases that cannot be controlled by Rust.
- C++ members
- Function return values.
§When not to use it?
Mainly those that can be controlled for safety on the Rust side.
- Function Arguments
§Convenient methods
to_enum
/from_enum
: To inter-convert enums.count
: Returns the number of defined discriminants.
§Memory Layout
It will always have #[repr(transparent)]
.
In other words, it is equivalent to the size specified in repr
.
Tuple Fields§
§0: u32
Implementations§
Source§impl INPUT_CONTEXT_ID_SE_CEnum
impl INPUT_CONTEXT_ID_SE_CEnum
pub const Gameplay: Self
pub const MenuMode: Self
pub const Console: Self
pub const ItemMenu: Self
pub const Inventory: Self
pub const DebugText: Self
pub const Favorites: Self
pub const Map: Self
pub const Stats: Self
pub const Cursor: Self
pub const Book: Self
pub const DebugOverlay: Self
pub const Journal: Self
pub const TFCMode: Self
pub const MapDebug: Self
pub const Lockpicking: Self
pub const Favor: Self
Sourcepub const fn to_enum(self) -> Option<INPUT_CONTEXT_ID_SE>
pub const fn to_enum(self) -> Option<INPUT_CONTEXT_ID_SE>
Converts to the corresponding enum
variant.
Returns Some(INPUT_CONTEXT_ID_SE)
if the value is valid, otherwise None
.
Sourcepub const fn from_enum(e: INPUT_CONTEXT_ID_SE) -> Self
pub const fn from_enum(e: INPUT_CONTEXT_ID_SE) -> Self
Creates the struct from the enum
.
This allows for easy conversion back to the FFI-friendly representation.
Trait Implementations§
Source§impl Clone for INPUT_CONTEXT_ID_SE_CEnum
impl Clone for INPUT_CONTEXT_ID_SE_CEnum
Source§fn clone(&self) -> INPUT_CONTEXT_ID_SE_CEnum
fn clone(&self) -> INPUT_CONTEXT_ID_SE_CEnum
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for INPUT_CONTEXT_ID_SE_CEnum
impl Debug for INPUT_CONTEXT_ID_SE_CEnum
Source§impl Default for INPUT_CONTEXT_ID_SE_CEnum
impl Default for INPUT_CONTEXT_ID_SE_CEnum
Source§impl From<INPUT_CONTEXT_ID_SE> for INPUT_CONTEXT_ID_SE_CEnum
impl From<INPUT_CONTEXT_ID_SE> for INPUT_CONTEXT_ID_SE_CEnum
Source§fn from(value: INPUT_CONTEXT_ID_SE) -> Self
fn from(value: INPUT_CONTEXT_ID_SE) -> Self
Converts to this type from the input type.
Source§impl Hash for INPUT_CONTEXT_ID_SE_CEnum
impl Hash for INPUT_CONTEXT_ID_SE_CEnum
Source§impl Ord for INPUT_CONTEXT_ID_SE_CEnum
impl Ord for INPUT_CONTEXT_ID_SE_CEnum
Source§fn cmp(&self, other: &INPUT_CONTEXT_ID_SE_CEnum) -> Ordering
fn cmp(&self, other: &INPUT_CONTEXT_ID_SE_CEnum) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialOrd for INPUT_CONTEXT_ID_SE_CEnum
impl PartialOrd for INPUT_CONTEXT_ID_SE_CEnum
impl Copy for INPUT_CONTEXT_ID_SE_CEnum
impl Eq for INPUT_CONTEXT_ID_SE_CEnum
impl StructuralPartialEq for INPUT_CONTEXT_ID_SE_CEnum
Auto Trait Implementations§
impl Freeze for INPUT_CONTEXT_ID_SE_CEnum
impl RefUnwindSafe for INPUT_CONTEXT_ID_SE_CEnum
impl Send for INPUT_CONTEXT_ID_SE_CEnum
impl Sync for INPUT_CONTEXT_ID_SE_CEnum
impl Unpin for INPUT_CONTEXT_ID_SE_CEnum
impl UnwindSafe for INPUT_CONTEXT_ID_SE_CEnum
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