pub enum Contribution {
System(SystemDecl),
Resource(ResourceDecl),
Plugin(String),
ServiceDomain(String),
}Expand description
Declarative interface from WASM plugin to Host.
A WASM plugin’s plugin_build() returns a list of Contributions
describing what the plugin wants to add to the Bevy App. The Host
applies these contributions after collecting them from all plugins.
The plugin never receives &mut App directly.
Variants§
System(SystemDecl)
Add a system to a Bevy schedule.
Resource(ResourceDecl)
Add a resource with a default value.
Plugin(String)
Add a known Bevy Plugin (referenced by name).
ServiceDomain(String)
Reserve a service domain (prevents conflicts).
Trait Implementations§
Source§impl Clone for Contribution
impl Clone for Contribution
Source§fn clone(&self) -> Contribution
fn clone(&self) -> Contribution
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for Contribution
impl Debug for Contribution
Source§impl<'de> Deserialize<'de> for Contribution
impl<'de> Deserialize<'de> for Contribution
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Contribution
impl RefUnwindSafe for Contribution
impl Send for Contribution
impl Sync for Contribution
impl Unpin for Contribution
impl UnsafeUnpin for Contribution
impl UnwindSafe for Contribution
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more