Struct winresult_types::HResult
source · [−]#[repr(transparent)]pub struct HResult(_);Expand description
[docs.microsoft.com] HRESULT
Implementations
sourceimpl HResult
impl HResult
pub const fn is_error(self) -> bool
pub const fn is_customer(self) -> bool
pub const fn is_ntstatus(self) -> bool
pub const fn facility(self) -> u16
pub const fn code(self) -> u16
pub const fn to_u32(self) -> u32
pub const fn succeeded(self) -> Result<HResultSuccess, HResultError>
Trait Implementations
sourceimpl From<(HResultFacilityMicrosoft, ErrorCode)> for HResult
impl From<(HResultFacilityMicrosoft, ErrorCode)> for HResult
sourcefn from((fac, code): (HResultFacilityMicrosoft, ErrorCode)) -> Self
fn from((fac, code): (HResultFacilityMicrosoft, ErrorCode)) -> Self
Converts to this type from the input type.
sourceimpl From<HResultError> for HResult
impl From<HResultError> for HResult
sourcefn from(hr: HResultError) -> Self
fn from(hr: HResultError) -> Self
Converts to this type from the input type.
sourceimpl From<HResultSuccess> for HResult
impl From<HResultSuccess> for HResult
sourcefn from(hr: HResultSuccess) -> Self
fn from(hr: HResultSuccess) -> Self
Converts to this type from the input type.
sourceimpl Ord for HResult
impl Ord for HResult
1.21.0 · sourcefn max(self, other: Self) -> Self
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
1.21.0 · sourcefn min(self, other: Self) -> Self
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
1.50.0 · sourcefn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
fn clamp(self, min: Self, max: Self) -> Selfwhere
Self: PartialOrd<Self>,
Restrict a value to a certain interval. Read more
sourceimpl PartialEq<HResultError> for HResult
impl PartialEq<HResultError> for HResult
sourcefn eq(&self, other: &HResultError) -> bool
fn eq(&self, other: &HResultError) -> bool
sourceimpl PartialEq<HResultSuccess> for HResult
impl PartialEq<HResultSuccess> for HResult
sourcefn eq(&self, other: &HResultSuccess) -> bool
fn eq(&self, other: &HResultSuccess) -> bool
sourceimpl PartialOrd<HResult> for HResult
impl PartialOrd<HResult> for HResult
sourcefn partial_cmp(&self, other: &HResult) -> Option<Ordering>
fn partial_cmp(&self, other: &HResult) -> Option<Ordering>
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self and other) and is used by the <=
operator. Read moreimpl Copy for HResult
impl Eq for HResult
impl Pod for HResult
impl StructuralEq for HResult
impl StructuralPartialEq for HResult
Auto Trait Implementations
impl RefUnwindSafe for HResult
impl Send for HResult
impl Sync for HResult
impl Unpin for HResult
impl UnwindSafe for HResult
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
type Bits = T
type Bits = T
Self must have the same layout as the specified Bits except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern. Read more