pub struct DInclinationEvent { /* private fields */ }Expand description
Dynamic-sized inclination event detector
Implementations§
Source§impl DInclinationEvent
impl DInclinationEvent
Sourcepub fn new(
value: f64,
name: impl Into<String>,
direction: EventDirection,
angle_format: AngleFormat,
) -> Self
pub fn new( value: f64, name: impl Into<String>, direction: EventDirection, angle_format: AngleFormat, ) -> Self
Create new inclination event
§Arguments
value- Inclination valuename- Event namedirection- Detection directionangle_format- Whether value is in degrees or radians
Sourcepub fn with_instance(self, instance: usize) -> Self
pub fn with_instance(self, instance: usize) -> Self
Set instance number for display name
Sourcepub fn with_tolerances(self, time_tol: f64, value_tol: f64) -> Self
pub fn with_tolerances(self, time_tol: f64, value_tol: f64) -> Self
Set custom tolerances for event detection
Sourcepub fn with_step_reduction_factor(self, factor: f64) -> Self
pub fn with_step_reduction_factor(self, factor: f64) -> Self
Set custom step reduction factor for bisection search
Sourcepub fn with_callback(self, callback: DEventCallback) -> Self
pub fn with_callback(self, callback: DEventCallback) -> Self
Set event callback
Sourcepub fn set_terminal(self) -> Self
pub fn set_terminal(self) -> Self
Mark as terminal event
Trait Implementations§
Source§impl DEventDetector for DInclinationEvent
impl DEventDetector for DInclinationEvent
Source§fn evaluate(
&self,
t: Epoch,
state: &DVector<f64>,
params: Option<&DVector<f64>>,
) -> f64
fn evaluate( &self, t: Epoch, state: &DVector<f64>, params: Option<&DVector<f64>>, ) -> f64
Evaluate the monitored value Read more
Source§fn target_value(&self) -> f64
fn target_value(&self) -> f64
Get target value for comparison Read more
Source§fn direction(&self) -> EventDirection
fn direction(&self) -> EventDirection
Get detection direction
Source§fn time_tolerance(&self) -> f64
fn time_tolerance(&self) -> f64
Get time tolerance (seconds)
Source§fn value_tolerance(&self) -> f64
fn value_tolerance(&self) -> f64
Get value tolerance
Source§fn step_reduction_factor(&self) -> f64
fn step_reduction_factor(&self) -> f64
Get step reduction factor for bisection search Read more
Source§fn callback(&self) -> Option<&DEventCallback>
fn callback(&self) -> Option<&DEventCallback>
Get optional callback
Source§fn action(&self) -> EventAction
fn action(&self) -> EventAction
Get action to take when event is detected Read more
Source§fn event_type(&self) -> EventType
fn event_type(&self) -> EventType
Get event type
Source§fn mark_processed(&self)
fn mark_processed(&self)
Mark this event as processed (callback has been executed) Read more
Source§fn is_processed(&self) -> bool
fn is_processed(&self) -> bool
Check if this event has been processed Read more
Source§fn reset_processed(&self)
fn reset_processed(&self)
Reset the processed state Read more
Auto Trait Implementations§
impl Freeze for DInclinationEvent
impl !RefUnwindSafe for DInclinationEvent
impl Send for DInclinationEvent
impl Sync for DInclinationEvent
impl Unpin for DInclinationEvent
impl UnsafeUnpin for DInclinationEvent
impl !UnwindSafe for DInclinationEvent
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.