#[non_exhaustive]pub enum GenerationParameterIssue {
InvalidCoordinateRange,
InvalidToroidalDomain,
NonFiniteVertexCoordinate,
InsufficientVertexCount,
InsufficientVerticesPerSlice,
InsufficientNumberOfTimeSlices,
NonPositiveSliceCount,
EmptyVolumeProfile,
VolumeProfileLengthOverflow,
InsufficientVerticesInVolumeProfileSlice,
VertexCountOverflow,
SimplexCountOverflow,
}Expand description
Identifies the issue category for invalid triangulation generation parameters.
Use this with CdtError::InvalidGenerationParameters when a constructor
rejects input before attempting triangulation.
§Examples
use causal_triangulations::prelude::errors::{CdtError, GenerationParameterIssue};
use causal_triangulations::prelude::triangulation::CdtTriangulation;
use std::assert_matches;
let err = CdtTriangulation::from_random_points(2, 2, 2)
.expect_err("fewer than three vertices cannot form a triangulation");
assert_matches!(
err,
CdtError::InvalidGenerationParameters {
issue: GenerationParameterIssue::InsufficientVertexCount,
..
}
);Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
InvalidCoordinateRange
Coordinate range has invalid ordering or bounds.
InvalidToroidalDomain
Toroidal domain extents are invalid.
NonFiniteVertexCoordinate
A supplied vertex coordinate is NaN or infinite.
InsufficientVertexCount
Total vertex count is below the constructor minimum.
InsufficientVerticesPerSlice
Per-slice vertex count is below the constructor minimum.
InsufficientNumberOfTimeSlices
Number of time slices is below the topology minimum.
NonPositiveSliceCount
A slice count was zero where at least one slice is required.
EmptyVolumeProfile
Explicit volume profile has no slices.
VolumeProfileLengthOverflow
Explicit volume profile length cannot fit in supported counters.
InsufficientVerticesInVolumeProfileSlice
A volume-profile slice has too few vertices.
VertexCountOverflow
Total vertex count cannot fit in supported counters.
SimplexCountOverflow
Simplex count cannot fit in supported counters.
Trait Implementations§
Source§impl Clone for GenerationParameterIssue
impl Clone for GenerationParameterIssue
Source§fn clone(&self) -> GenerationParameterIssue
fn clone(&self) -> GenerationParameterIssue
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for GenerationParameterIssue
impl Debug for GenerationParameterIssue
Source§impl Display for GenerationParameterIssue
impl Display for GenerationParameterIssue
Source§impl Hash for GenerationParameterIssue
impl Hash for GenerationParameterIssue
Source§impl PartialEq for GenerationParameterIssue
impl PartialEq for GenerationParameterIssue
Source§fn eq(&self, other: &GenerationParameterIssue) -> bool
fn eq(&self, other: &GenerationParameterIssue) -> bool
self and other values to be equal, and is used by ==.