pub trait MessageType: Serialize + DeserializeOwned {
// Required method
fn id() -> &'static str;
}
Expand description
Represents a message type that can be sent between scripts or from the engine. The MessageType::id method should return a globally unique identifier for the message type. If in doubt, use a UUID.
Required 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.