Expand description
§Windows async types
The windows-future crate provides stock async support for Windows APIs.
Start by adding the following to your Cargo.toml file:
[dependencies.windows-future]
version = "0.1"
Use the Windows async types as needed:
use windows_future::*;
use windows_result::*;
fn main() -> Result<()> {
// This result will be available immediately.
let ready = IAsyncOperation::ready(Ok(123));
assert_eq!(ready.get()?, 123);
let ready = IAsyncOperation::spawn(|| {
// Some lengthy operation goes here...
Ok(456)
});
assert_eq!(ready.get()?, 456);
Ok(())
}
Structs§
- Async
Action Completed Handler - Async
Action Completed Handler_ Vtbl - Async
Action Progress Handler - Async
Action Progress Handler_ Vtbl - Async
Action With Progress Completed Handler - Async
Action With Progress Completed Handler_ Vtbl - Async
Operation Completed Handler - Async
Operation Completed Handler_ Vtbl - Async
Operation Progress Handler - Async
Operation Progress Handler_ Vtbl - Async
Operation With Progress Completed Handler - Async
Operation With Progress Completed Handler_ Vtbl - Async
Status - IAsync
Action - IAsync
Action With Progress - IAsync
Action With Progress_ Vtbl - IAsync
Action_ Vtbl - IAsync
Info - IAsync
Info_ Vtbl - IAsync
Operation - IAsync
Operation With Progress - IAsync
Operation With Progress_ Vtbl - IAsync
Operation_ Vtbl