pub struct VariableDecl {
pub name: String,
pub value: BehaviorLiteral,
}Expand description
One variable declared by the world’s Variables. The declared value fixes both the variable’s type and the value it holds at world start.
Fields§
§name: StringThe name behaviors read and write the variable by.
value: BehaviorLiteralThe variable’s type and starting value.
Trait Implementations§
Source§impl Clone for VariableDecl
impl Clone for VariableDecl
Source§fn clone(&self) -> VariableDecl
fn clone(&self) -> VariableDecl
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 VariableDecl
impl Debug for VariableDecl
Source§impl Default for VariableDecl
impl Default for VariableDecl
Source§fn default() -> VariableDecl
fn default() -> VariableDecl
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for VariableDeclwhere
VariableDecl: Default,
impl<'de> Deserialize<'de> for VariableDeclwhere
VariableDecl: Default,
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<VariableDecl, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<VariableDecl, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for VariableDecl
impl Serialize for VariableDecl
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for VariableDecl
impl RefUnwindSafe for VariableDecl
impl Send for VariableDecl
impl Sync for VariableDecl
impl Unpin for VariableDecl
impl UnsafeUnpin for VariableDecl
impl UnwindSafe for VariableDecl
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