pub enum Error {
NoParticles,
CloseEncounter,
Escape,
Collision,
IntegrationFailed(i32),
Other(String),
}Expand description
Errors produced by the low-level REBOUND FFI wrappers.
Covers REBOUND integration-exit conditions. Higher-level errors (ASSIST
ephemeris failures, light-time convergence, etc.) live in downstream
crates that wrap this type via #[from].
Variants§
NoParticles
Integration ended early because no particles remain (REB_STATUS_NO_PARTICLES).
CloseEncounter
Integration ended early because two particles had a close encounter
(REB_STATUS_ENCOUNTER; triggered by exit_min_distance).
Escape
Integration ended early because a particle escaped
(REB_STATUS_ESCAPE; triggered by exit_max_distance).
Collision
Integration ended early because two particles collided
(REB_STATUS_COLLISION).
IntegrationFailed(i32)
REBOUND returned a generic/unknown error status.
Holds the raw REB_STATUS code for diagnostics; use the named variants
above to match on the common integration-exit conditions.
Other(String)
Trait Implementations§
Source§impl Error for Error
impl Error for Error
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()