pub struct Servo<A: Automaton> { /* private fields */ }Expand description
Сервопривод — связывает автомат с параметром узла
Implementations§
Source§impl<A: Automaton> Servo<A>
impl<A: Automaton> Servo<A>
pub fn new( id: impl Into<String>, automaton: A, target_node: NodeId, target_param: impl Into<String>, mapping: ParameterMapping, min: f64, max: f64, ) -> Self
Sourcepub fn update(&mut self, time: Time) -> Option<ParameterCommand>
pub fn update(&mut self, time: Time) -> Option<ParameterCommand>
Обновить сервопривод и вернуть команду, если значение изменилось
Sourcepub fn set_enabled(&mut self, enabled: bool)
pub fn set_enabled(&mut self, enabled: bool)
Включить/выключить сервопривод
Trait Implementations§
Auto Trait Implementations§
impl<A> Freeze for Servo<A>
impl<A> !RefUnwindSafe for Servo<A>
impl<A> Send for Servo<A>
impl<A> Sync for Servo<A>
impl<A> Unpin for Servo<A>
impl<A> UnsafeUnpin for Servo<A>
impl<A> !UnwindSafe for Servo<A>
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