ProcessHandleInfo

Struct ProcessHandleInfo 

Source
pub struct ProcessHandleInfo<'a, P: Process + ?Sized> {
    pub handle: Handle,
    pub access: u32,
    pub object_type: u32,
    pub count: usize,
    pub pointer_count: usize,
    pub attributes: u32,
    /* private fields */
}
Expand description

Represents a handle that a process has opened.

Fields§

§handle: Handle

The value of the handle.

§access: u32

The raw access mask of the object handle.

§object_type: u32

The type identifier of the object

§count: usize

The number of references to the handle.

§pointer_count: usize

The number of pointers to the handle.

§attributes: u32

The attributes of the handle.

Implementations§

Source§

impl<'a, P: Process> ProcessHandleInfo<'a, P>

Source

pub fn duplicate_handle(&self, access: Option<u32>) -> Result<Handle>

Duplicates the handle.

§Access Rights

This method requires an object access mask beyond standard bounds like process access and thread access. Therefore, the desired access has been kept in its raw state as a u32. However, if the access is None, it will copy the handle’s original access mask.

Source

pub fn name(&self) -> Result<String>

Retrieves the name of the object, if present.

The name can include path separators (“\”).

Source

pub fn type_name(&self) -> Result<String>

Retrieves the type name of the object.

Trait Implementations§

Source§

impl<'a, P: Clone + Process + ?Sized> Clone for ProcessHandleInfo<'a, P>

Source§

fn clone(&self) -> ProcessHandleInfo<'a, P>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<'a, P: Debug + Process + ?Sized> Debug for ProcessHandleInfo<'a, P>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'a, P: Process> Into<HandleObject> for ProcessHandleInfo<'a, P>

Source§

fn into(self) -> HandleObject

Converts this type into the (usually inferred) input type.

Auto Trait Implementations§

§

impl<'a, P> Freeze for ProcessHandleInfo<'a, P>
where P: ?Sized,

§

impl<'a, P> RefUnwindSafe for ProcessHandleInfo<'a, P>
where P: RefUnwindSafe + ?Sized,

§

impl<'a, P> Send for ProcessHandleInfo<'a, P>
where P: Sync + ?Sized,

§

impl<'a, P> Sync for ProcessHandleInfo<'a, P>
where P: Sync + ?Sized,

§

impl<'a, P> Unpin for ProcessHandleInfo<'a, P>
where P: ?Sized,

§

impl<'a, P> UnwindSafe for ProcessHandleInfo<'a, P>
where P: RefUnwindSafe + ?Sized,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.