pub trait ErasedRenderObject:
Copy
+ PartialEq
+ Debug
+ 'static {
// Required methods
fn as_object(self) -> AnyRenderObject;
fn from_object(object: AnyRenderObject) -> Self;
}Expand description
An erased render object a parent can hold as a child: Dart’s ChildType extends RenderObject
type argument of RenderObjectWithChildMixin and ContainerRenderObjectMixin.
Implemented by crate::AnyRenderBox and crate::AnyRenderSliver.
Required Methods§
Sourcefn as_object(self) -> AnyRenderObject
fn as_object(self) -> AnyRenderObject
The RenderObject view of this handle.
Sourcefn from_object(object: AnyRenderObject) -> Self
fn from_object(object: AnyRenderObject) -> Self
Dart’s implicit downcast of a RenderObject to ChildType.
§Panics
If object does not use this protocol.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".