pub trait HasEvents {
// Required method
fn events() -> Vec<Event>;
// Provided method
fn event_schemas() -> BTreeMap<String, Schema> { ... }
}Expand description
A trait that should be implemented by each smart contract to allow the backend.
Required Methods§
Provided Methods§
Sourcefn event_schemas() -> BTreeMap<String, Schema>
fn event_schemas() -> BTreeMap<String, Schema>
Returns a map of event schemas used by the contract.
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.