Struct WindowsWindowHandleProbe
pub struct WindowsWindowHandleProbe<A = DefaultWindowsApi>where
A: WindowsApi,{
api: Arc<A>,
}Expand description
Window-handle probe backed by WindowsApi::get_window_handle_for_process.
Holds an Arc over a WindowsApi for the same testability reasons
as WindowsProcessSpawner.
Fields§
§api: Arc<A>Implementations§
Source§impl<A> WindowsWindowHandleProbe<A>where
A: WindowsApi,
impl<A> WindowsWindowHandleProbe<A>where
A: WindowsApi,
Sourcepub fn new(api: Arc<A>) -> WindowsWindowHandleProbe<A>
pub fn new(api: Arc<A>) -> WindowsWindowHandleProbe<A>
Construct a probe around a specific WindowsApi implementation.
§Arguments
api- Windows API operations implementation.
Trait Implementations§
Source§impl Default for WindowsWindowHandleProbe
impl Default for WindowsWindowHandleProbe
Source§fn default() -> WindowsWindowHandleProbe
fn default() -> WindowsWindowHandleProbe
Returns the “default value” for a type. Read more
Source§impl<A> WindowHandleProbe for WindowsWindowHandleProbe<A>where
A: WindowsApi + 'static,
impl<A> WindowHandleProbe for WindowsWindowHandleProbe<A>where
A: WindowsApi + 'static,
Source§type Handle = SendHwnd
type Handle = SendHwnd
Opaque platform-specific window handle type
(
HWND on Windows, X11 window XID, Wayland surface id, …).Source§fn window_handle_for_process(
&self,
pid: u32,
) -> Option<<WindowsWindowHandleProbe<A> as WindowHandleProbe>::Handle>
fn window_handle_for_process( &self, pid: u32, ) -> Option<<WindowsWindowHandleProbe<A> as WindowHandleProbe>::Handle>
Return a window handle owned by
pid, if one exists. Read moreAuto Trait Implementations§
impl<A> Freeze for WindowsWindowHandleProbe<A>
impl<A> RefUnwindSafe for WindowsWindowHandleProbe<A>where
A: RefUnwindSafe,
impl<A> Send for WindowsWindowHandleProbe<A>
impl<A> Sync for WindowsWindowHandleProbe<A>
impl<A> Unpin for WindowsWindowHandleProbe<A>
impl<A> UnsafeUnpin for WindowsWindowHandleProbe<A>
impl<A> UnwindSafe for WindowsWindowHandleProbe<A>where
A: RefUnwindSafe,
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