pub struct FunctionComposition { /* private fields */ }
Expand description
Corresponds to the grammar rule function_composition
.
§Well-Formedness Rules
- The list of function names MUST have at least one element.
$$\forall r \in FunctionComposition \left( |name(r)| \gte 1 \right)$$
§Semantics
The keyword self
may ONLY appear as the first element.
The name path $x.y.z$ is equivalent to $z(y(x))$, or $(z \circ y)(x)$.
For example:
self.name.length
becomes length(name(self))
Implementations§
Source§impl FunctionComposition
impl FunctionComposition
pub fn new<S, N>(subject: S, function_names: N) -> Self
pub fn subject(&self) -> &Subject
pub fn set_subject<S>(&mut self, subject: S)
pub fn has_function_names(&self) -> bool
pub fn function_names_len(&self) -> usize
pub fn function_names(&self) -> impl Iterator<Item = &Identifier>
pub fn function_names_mut(&mut self) -> impl Iterator<Item = &mut Identifier>
pub fn add_to_function_names<I>(&mut self, value: I)where
I: Into<Identifier>,
pub fn extend_function_names<I>(&mut self, extension: I)where
I: IntoIterator<Item = Identifier>,
Trait Implementations§
Source§impl Clone for FunctionComposition
impl Clone for FunctionComposition
Source§fn clone(&self) -> FunctionComposition
fn clone(&self) -> FunctionComposition
Returns a duplicate of the value. Read more
1.0.0 · 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 FunctionComposition
impl Debug for FunctionComposition
Source§impl<'de> Deserialize<'de> for FunctionComposition
impl<'de> Deserialize<'de> for FunctionComposition
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
Source§impl From<FunctionComposition> for FunctionBody
impl From<FunctionComposition> for FunctionBody
Source§fn from(value: FunctionComposition) -> FunctionBody
fn from(value: FunctionComposition) -> FunctionBody
Converts to this type from the input type.
Source§impl From<FunctionComposition> for Term
impl From<FunctionComposition> for Term
Source§fn from(v: FunctionComposition) -> Self
fn from(v: FunctionComposition) -> Self
Converts to this type from the input type.
Source§impl HasSourceSpan for FunctionComposition
impl HasSourceSpan for FunctionComposition
fn with_source_span(self, span: Span) -> Self
fn source_span(&self) -> Option<&Span>
fn set_source_span(&mut self, span: Span)
fn unset_source_span(&mut self)
fn has_source_span(&self) -> bool
Auto Trait Implementations§
impl Freeze for FunctionComposition
impl RefUnwindSafe for FunctionComposition
impl Send for FunctionComposition
impl Sync for FunctionComposition
impl Unpin for FunctionComposition
impl UnwindSafe for FunctionComposition
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