pub struct FuncParam {
pub key: Option<String>,
pub value: ParamValue,
}Expand description
A parameter to an evaluation function.
A None key is a positional parameter ('agile', 5); a Some key
is a keyword parameter (direction='below').
Fields§
§key: Option<String>The keyword name, if this is a keyword parameter.
value: ParamValueThe parameter value.
Implementations§
Source§impl FuncParam
impl FuncParam
Sourcepub fn positional(value: ParamValue) -> Self
pub fn positional(value: ParamValue) -> Self
A positional parameter.
Sourcepub fn keyword(key: impl Into<String>, value: ParamValue) -> Self
pub fn keyword(key: impl Into<String>, value: ParamValue) -> Self
A keyword parameter.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for FuncParam
impl<'de> Deserialize<'de> for FuncParam
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
impl StructuralPartialEq for FuncParam
Auto Trait Implementations§
impl Freeze for FuncParam
impl RefUnwindSafe for FuncParam
impl Send for FuncParam
impl Sync for FuncParam
impl Unpin for FuncParam
impl UnsafeUnpin for FuncParam
impl UnwindSafe for FuncParam
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