Enum SimulationError
pub enum SimulationError {
Show 15 variants
CalcError(CalcError),
TimeError(TimeError),
ControllerError(ControllerError),
DivisionError(DivisionError),
DeathError(DeathError),
BoundaryError(BoundaryError),
DrawingError(DrawingError),
IndexError(IndexError),
SendError(String),
ReceiveError(RecvError),
StorageError(StorageError),
IoError(Error),
RequestError(RequestError),
RngError(RngError),
ThreadingError(ThreadPoolBuildError),
}
cpu_os_threads
only.Expand description
Covers all errors that can occur in this Simulation
This main error type should be derivable from errors arising during the simulation process.
It is required for custom error types MyCustomError
of the engine to implement the
From<MyCustomError> for SimulationError
.
Errors are separated by their ability to be recovered, ignored or handled otherwise. Since this crate aims to provide an adaptive solving approach, it is desired to have a fallback mechanism which can be called for errors which may arise due to precision problems.
Variants§
CalcError(CalcError)
Occurs during calculations of any mathematical update steps such as Interaction between cells.
TimeError(TimeError)
Related to time-stepping events. See crate::time.
ControllerError(ControllerError)
Error-type specifically related to the Controller trait.
DivisionError(DivisionError)
An error specific to cell-division events by the
Cycle trait.
DeathError(DeathError)
Related to the PhasedDeath event. This error can only occur during the update_conditional_phased_death method.
BoundaryError(BoundaryError)
Enforcing boundary conditions on cells can exhibhit this boundary error.
DrawingError(DrawingError)
Plotting results. See also cellular_raza_concepts::PlotSelf and cellular_raza_concepts::CreatePlottingRoot.
IndexError(IndexError)
Mostly caused by trying to find a voxel by its index. This error can also occur when applying too large simulation-steps.
SendError(String)
Sending information between threads fails
ReceiveError(RecvError)
Receiving information from another thread fails
StorageError(StorageError)
Storing results fails
IoError(Error)
When writing to output files or reading from them. See std::io::Error
RequestError(RequestError)
Occurs when requested data could not be returned
RngError(RngError)
Errors related to rand and its functionalities
ThreadingError(ThreadPoolBuildError)
Errors surrounding construction of rayon::ThreadPool.
Trait Implementations§
§impl Debug for SimulationError
impl Debug for SimulationError
§impl Display for SimulationError
impl Display for SimulationError
§impl Error for SimulationError
impl Error for SimulationError
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
§impl From<BoundaryError> for SimulationError
impl From<BoundaryError> for SimulationError
§fn from(err: BoundaryError) -> SimulationError
fn from(err: BoundaryError) -> SimulationError
§impl From<CalcError> for SimulationError
impl From<CalcError> for SimulationError
§fn from(err: CalcError) -> SimulationError
fn from(err: CalcError) -> SimulationError
§impl From<ControllerError> for SimulationError
impl From<ControllerError> for SimulationError
§fn from(err: ControllerError) -> SimulationError
fn from(err: ControllerError) -> SimulationError
§impl From<DeathError> for SimulationError
impl From<DeathError> for SimulationError
§fn from(err: DeathError) -> SimulationError
fn from(err: DeathError) -> SimulationError
§impl From<DivisionError> for SimulationError
impl From<DivisionError> for SimulationError
§fn from(err: DivisionError) -> SimulationError
fn from(err: DivisionError) -> SimulationError
§impl<E> From<DrawingAreaErrorKind<E>> for SimulationError
impl<E> From<DrawingAreaErrorKind<E>> for SimulationError
§fn from(drawing_error: DrawingAreaErrorKind<E>) -> SimulationError
fn from(drawing_error: DrawingAreaErrorKind<E>) -> SimulationError
§impl From<DrawingError> for SimulationError
impl From<DrawingError> for SimulationError
§fn from(err: DrawingError) -> SimulationError
fn from(err: DrawingError) -> SimulationError
§impl From<Error> for SimulationError
impl From<Error> for SimulationError
§fn from(err: Error) -> SimulationError
fn from(err: Error) -> SimulationError
§impl From<IndexError> for SimulationError
impl From<IndexError> for SimulationError
§fn from(err: IndexError) -> SimulationError
fn from(err: IndexError) -> SimulationError
§impl From<RecvError> for SimulationError
impl From<RecvError> for SimulationError
§fn from(err: RecvError) -> SimulationError
fn from(err: RecvError) -> SimulationError
§impl From<RequestError> for SimulationError
impl From<RequestError> for SimulationError
§fn from(err: RequestError) -> SimulationError
fn from(err: RequestError) -> SimulationError
§impl From<RngError> for SimulationError
impl From<RngError> for SimulationError
§fn from(err: RngError) -> SimulationError
fn from(err: RngError) -> SimulationError
§impl<T> From<SendError<T>> for SimulationError
impl<T> From<SendError<T>> for SimulationError
§fn from(_err: SendError<T>) -> SimulationError
fn from(_err: SendError<T>) -> SimulationError
§impl From<StorageError> for SimulationError
impl From<StorageError> for SimulationError
§fn from(err: StorageError) -> SimulationError
fn from(err: StorageError) -> SimulationError
§impl From<ThreadPoolBuildError> for SimulationError
impl From<ThreadPoolBuildError> for SimulationError
§fn from(err: ThreadPoolBuildError) -> SimulationError
fn from(err: ThreadPoolBuildError) -> SimulationError
§impl From<TimeError> for SimulationError
impl From<TimeError> for SimulationError
§fn from(err: TimeError) -> SimulationError
fn from(err: TimeError) -> SimulationError
Auto Trait Implementations§
impl Freeze for SimulationError
impl !RefUnwindSafe for SimulationError
impl Send for SimulationError
impl Sync for SimulationError
impl Unpin for SimulationError
impl !UnwindSafe for SimulationError
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
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> ⓘ
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> ⓘ
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 more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self
from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self
is actually part of its subset T
(and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset
but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self
to the equivalent element of its superset.