pub trait DefinedClass: ClassType {
type Ivars: Sized;
// Provided method
fn ivars(&self) -> &Self::Ivars
where Self: Sized { ... }
}
Expand description
Marks class types whose implementation is defined in Rust.
This is used in define_class!
, and allows access to the instance
variables that a given type declares, see that macro for details.
Required Associated Types§
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.