pub unsafe trait Interface: Unknown {
type Vtbl;
const IID: [u8; 16];
// Required method
fn inherits(iid: &[u8; 16]) -> bool;
}
Expand description
Implemented by all COM interface types.
§Safety
If a type I
implements Interface
, it must have the same layout as the pointer type
*const I::Vtbl
.
If I::inherits(J::IID)
returns true
, then the layout of J::Vtbl
must be a prefix of the
layout of I::Vtbl
, i.e. a valid pointer to an instance of I::Vtbl
must also be valid
pointer to an instance of J::Vtbl
.
Required Associated Types§
Required Associated Constants§
Required Methods§
Object Safety§
This trait is not object safe.