Expand description
Types and traits related to type erasure.
Re-exports§
pub use crate::type_level::downcasting::TD_CanDowncast;
pub use crate::type_level::downcasting::TD_Opaque;
Modules§
- interfaces
- Types that implement
InterfaceType
, used in examples. - trait_
objects - Ffi-safe trait objects for individual traits.
Structs§
- DynTrait
- DynTrait implements ffi-safe trait objects, for a selection of traits.
- Required
Traits - Describes which traits are required and enabled by the
I:
InterfaceType
that thisRequiredTraits
is created from. - Type
Info - Metadata about a type.
- Unerase
Error - Error for
DynTrait<_>
being downcasted into the wrong type with one of the*downcasted*
methods. - VTable_
Ref - A pointer to the vtable of
DynTrait
.
Traits§
- Deserialize
Dyn - Describes how
D
is deserialized, using a proxy to do so. - Interface
Type - Defines the usable/required traits when creating a
DynTrait<Pointer<()>, ThisInterfaceType>
. - Iterator
Item - The way to specify the expected
Iterator::Item
type for anInterfaceType
. - Iterator
Item OrDefault - Gets the expected
Iterator::Item
type for anInterfaceType
, defaulting to()
if it doesn’t requireIterator
to be implemented. - Make
Required Traits - For constructing a
RequiredTraits
constant. - MakeV
Table - Csontructs a vtable.
- Serialize
Proxy Type - Determines the intermediate type a
SerializeType
implementor is converted into, and is then serialized. - Serialize
Type - Describes how a type is serialized by
DynTrait
.