pub struct Behavior {
pub name: Token,
pub loc: FileLocation,
pub cases: Map<String, BehaviorCase>,
pub stringency: Stringency,
}
Expand description
Behavior requirement or constraint. States how variable values should respond to sets of values for stimuli.
Fields§
§name: Token
Behavior’s name or label.
loc: FileLocation
Complete behavior’s textual location.
cases: Map<String, BehaviorCase>
All cases as mapping from their names to the case.
stringency: Stringency
Whether this is a requirement or a constraint.
Trait Implementations§
Source§impl<'a> FetchTarget<'a, Behavior> for BehaviorTarget
impl<'a> FetchTarget<'a, Behavior> for BehaviorTarget
Source§fn fetch_values(
&self,
spec: &'a Specification,
) -> Result<&'a [Behavior], TargetError<Self>>
fn fetch_values( &self, spec: &'a Specification, ) -> Result<&'a [Behavior], TargetError<Self>>
Fetch the map reference containing the targeted item.
Source§fn fetch_values_mut(
&self,
spec: &'a mut Specification,
) -> Result<&'a mut [Behavior], TargetError<Self>>
fn fetch_values_mut( &self, spec: &'a mut Specification, ) -> Result<&'a mut [Behavior], TargetError<Self>>
Fetch the mutable map reference containing the targeted item.
Source§fn fetch(&self, spec: &'a Specification) -> Result<&'a V, TargetError<Self>>
fn fetch(&self, spec: &'a Specification) -> Result<&'a V, TargetError<Self>>
Fetch a reference to the target from the specification.
Source§fn fetch_mut(
&self,
spec: &'a mut Specification,
) -> Result<&'a mut V, TargetError<Self>>
fn fetch_mut( &self, spec: &'a mut Specification, ) -> Result<&'a mut V, TargetError<Self>>
Fetch a mutable reference to the target from the specification.
impl StructuralPartialEq for Behavior
Auto Trait Implementations§
impl Freeze for Behavior
impl RefUnwindSafe for Behavior
impl !Send for Behavior
impl !Sync for Behavior
impl Unpin for Behavior
impl UnwindSafe for Behavior
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