pub trait AssociateClass {
// Required method
fn associate_class(&mut self, class: InterfaceClass) -> bool;
}
Expand description
An object that can be associate with an InterfaceClass
.
Required Methods§
Sourcefn associate_class(&mut self, class: InterfaceClass) -> bool
fn associate_class(&mut self, class: InterfaceClass) -> bool
Check if this object is a valid object for the given interface class
I
.
Returns Some(self)
if this is a valid instance of the interface, and
None
otherwise.
Classes constructed by InterfaceClass
are unique per type, so
repeatedly calling this method for the same InterfaceClass
is allowed.