use crate::{dbgeng::WinResult, dbgmodel::*, *};
use windows::Win32::System::Diagnostics::Debug::Extensions::IDebugHost;
use windows_core::IUnknown;
impl_debug_interface!(DebugHost, DebugHostRef, IDebugHost);
impl DebugHost {
pub fn get_host_defined_interface(&self) -> WinResult<IUnknown> {
unsafe { self.0.GetHostDefinedInterface() }
}
pub fn get_current_context(&self) -> WinResult<DebugHostContext> {
unsafe { Ok(self.0.GetCurrentContext()?.into()) }
}
pub fn get_default_metadata(&self) -> WinResult<KeyStore> {
unsafe { Ok(self.0.GetDefaultMetadata()?.into()) }
}
}