#[non_exhaustive]pub enum InvalidBlockGraphError {
Show 19 variants
NotExactlySinglePipe(IVec3),
SpatialPipeNotAllowed(IVec3),
SpatialPortRoleRequired(IVec3),
TemporalPortRoleMismatch {
pos: IVec3,
declared: PortRole,
inferred: PortRole,
},
FuturePipeNotAllowed(IVec3),
PastPipeNotAllowed(IVec3),
OrientationContradiction(IVec3, IVec3),
JunctionNotPlanar(IVec3),
DegeneratePipeFace(IVec3, IVec3),
CubeHeightSpatialMismatch {
pos: IVec3,
neighbor: IVec3,
height: CubeHeight,
neighbor_height: CubeHeight,
},
CubeInvalidPipeEndpoint {
pos: IVec3,
endpoint: IVec3,
},
BlockFootprintOverlap {
pos: IVec3,
},
WalkingPipeNotTemporal {
pos: IVec3,
endpoint: IVec3,
},
WalkingStartPipeNotPast {
pos: IVec3,
},
WalkingEndPipeNotFuture {
pos: IVec3,
},
PatchRotationEndpointPipeCount {
pos: IVec3,
endpoint: IVec3,
count: usize,
},
PatchRotationPipeNotTemporal {
pos: IVec3,
endpoint: IVec3,
},
PatchRotationStartPipeHadamard {
pos: IVec3,
},
PatchRotationBoundaryMismatch {
pos: IVec3,
endpoint: IVec3,
expected: Basis,
actual: Option<Basis>,
},
}Expand description
A structural well-formedness violation found while validating a
BlockGraph’s blocks, pipes, and lattice-surgery
geometry.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
NotExactlySinglePipe(IVec3)
A block kind requiring one pipe has a different degree.
SpatialPipeNotAllowed(IVec3)
A block kind that accepts only temporal pipes has a spatial pipe.
SpatialPortRoleRequired(IVec3)
A spatial port lacks an explicit input, output, or multiplex role.
TemporalPortRoleMismatch
A temporal port’s declared role disagrees with its pipe direction.
Fields
pos: IVec3Port position.
FuturePipeNotAllowed(IVec3)
A block accepts only a pipe extending into its past.
PastPipeNotAllowed(IVec3)
A block accepts only a pipe extending into its future.
OrientationContradiction(IVec3, IVec3)
Adjacent block faces imply incompatible lattice-surgery orientations.
JunctionNotPlanar(IVec3)
A multi-pipe junction does not lie in one plane.
DegeneratePipeFace(IVec3, IVec3)
A pipe face has the same basis on both perpendicular axes.
CubeHeightSpatialMismatch
Spatially connected cubes have different symbolic heights.
Fields
pos: IVec3First cube position.
neighbor: IVec3Neighboring cube position.
height: CubeHeightFirst cube height.
neighbor_height: CubeHeightNeighboring cube height.
CubeInvalidPipeEndpoint
A pipe attaches to an invalid cell of a multi-cell cube.
BlockFootprintOverlap
Two block footprints reserve the same lattice cell.
Fields
pos: IVec3Multiply occupied lattice cell.
WalkingPipeNotTemporal
A walking block endpoint has a spatial pipe.
WalkingStartPipeNotPast
A walking block’s start endpoint has a non-past pipe.
Fields
pos: IVec3Walking-block anchor position.
WalkingEndPipeNotFuture
A walking block’s end endpoint has a non-future pipe.
Fields
pos: IVec3Walking-block anchor position.
PatchRotationEndpointPipeCount
A patch-rotation endpoint does not have exactly one temporal pipe.
PatchRotationPipeNotTemporal
A patch-rotation endpoint has a spatial pipe.
PatchRotationStartPipeHadamard
A patch rotation has a Hadamard pipe at its start endpoint.
Fields
pos: IVec3Patch-rotation anchor position.
PatchRotationBoundaryMismatch
A patch-rotation endpoint has the wrong boundary orientation.
Trait Implementations§
Source§impl Clone for InvalidBlockGraphError
impl Clone for InvalidBlockGraphError
Source§fn clone(&self) -> InvalidBlockGraphError
fn clone(&self) -> InvalidBlockGraphError
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 InvalidBlockGraphError
impl Debug for InvalidBlockGraphError
Source§impl Display for InvalidBlockGraphError
impl Display for InvalidBlockGraphError
Source§impl Error for InvalidBlockGraphError
impl Error for InvalidBlockGraphError
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()
Source§impl From<InvalidBlockGraphError> for BlockGraphError
impl From<InvalidBlockGraphError> for BlockGraphError
Source§fn from(source: InvalidBlockGraphError) -> Self
fn from(source: InvalidBlockGraphError) -> Self
Auto Trait Implementations§
impl Freeze for InvalidBlockGraphError
impl RefUnwindSafe for InvalidBlockGraphError
impl Send for InvalidBlockGraphError
impl Sync for InvalidBlockGraphError
impl Unpin for InvalidBlockGraphError
impl UnsafeUnpin for InvalidBlockGraphError
impl UnwindSafe for InvalidBlockGraphError
Blanket Implementations§
§impl<T, BorrowedSelf> BitwiseMutViaBorrow<BorrowedSelf> for T
impl<T, BorrowedSelf> BitwiseMutViaBorrow<BorrowedSelf> for T
fn assign_index(&mut self, index: usize, to: bool)
fn negate_index(&mut self, index: usize)
fn clear_bits(&mut self)
fn assign_random(
&mut self,
bit_count: usize,
random_number_generator: &mut impl RngExt,
)where
BorrowedSelf: BitLength,
§impl<Bits, Other, BorrowedSelf, BorrowedOther> BitwisePairMutViaBorrow<Other, BorrowedSelf, BorrowedOther> for Bits
impl<Bits, Other, BorrowedSelf, BorrowedOther> BitwisePairMutViaBorrow<Other, BorrowedSelf, BorrowedOther> for Bits
fn assign(&mut self, other: &Other)
fn bitxor_assign(&mut self, other: &Other)
fn bitand_assign(&mut self, other: &Other)
fn bitor_assign(&mut self, other: &Other)
§impl<T, Other, BorrowedSelf, BorrowedOther> BitwisePairViaBorrow<Other, BorrowedSelf, BorrowedOther> for T
impl<T, Other, BorrowedSelf, BorrowedOther> BitwisePairViaBorrow<Other, BorrowedSelf, BorrowedOther> for T
§impl<T, BorrowedSelf> BitwiseViaBorrow<BorrowedSelf> for T
impl<T, BorrowedSelf> BitwiseViaBorrow<BorrowedSelf> for T
fn index(&self, index: usize) -> bool
fn weight(&self) -> usize
fn parity(&self) -> bool
fn is_zero(&self) -> bool
fn is_unit(&self, index: usize) -> bool
fn support<'a>(&'a self) -> impl SortedIteratorwhere
BorrowedSelf: 'a,
fn max_support(&self) -> Option<usize>
fn min_support(&self) -> Option<usize>
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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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<'src, T> IntoMaybe<'src, T> for Twhere
T: 'src,
impl<'src, T> IntoMaybe<'src, T> for Twhere
T: 'src,
impl<T> OrderedSeq<'_, T> for Twhere
T: Clone,
§impl<T> Paint for Twhere
T: ?Sized,
impl<T> Paint for Twhere
T: ?Sized,
§fn fg(&self, value: Color) -> Painted<&T>
fn fg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self with the foreground set to
value.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like red() and
green(), which have the same functionality but are
pithier.
§Example
Set foreground color to white using fg():
use yansi::{Paint, Color};
painted.fg(Color::White);Set foreground color to white using white().
use yansi::Paint;
painted.white();§fn bright_black(&self) -> Painted<&T>
fn bright_black(&self) -> Painted<&T>
§fn bright_red(&self) -> Painted<&T>
fn bright_red(&self) -> Painted<&T>
§fn bright_green(&self) -> Painted<&T>
fn bright_green(&self) -> Painted<&T>
§fn bright_yellow(&self) -> Painted<&T>
fn bright_yellow(&self) -> Painted<&T>
§fn bright_blue(&self) -> Painted<&T>
fn bright_blue(&self) -> Painted<&T>
§fn bright_magenta(&self) -> Painted<&T>
fn bright_magenta(&self) -> Painted<&T>
§fn bright_cyan(&self) -> Painted<&T>
fn bright_cyan(&self) -> Painted<&T>
§fn bright_white(&self) -> Painted<&T>
fn bright_white(&self) -> Painted<&T>
§fn bg(&self, value: Color) -> Painted<&T>
fn bg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self with the background set to
value.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like on_red() and
on_green(), which have the same functionality but
are pithier.
§Example
Set background color to red using fg():
use yansi::{Paint, Color};
painted.bg(Color::Red);Set background color to red using on_red().
use yansi::Paint;
painted.on_red();§fn on_primary(&self) -> Painted<&T>
fn on_primary(&self) -> Painted<&T>
§fn on_magenta(&self) -> Painted<&T>
fn on_magenta(&self) -> Painted<&T>
§fn on_bright_black(&self) -> Painted<&T>
fn on_bright_black(&self) -> Painted<&T>
§fn on_bright_red(&self) -> Painted<&T>
fn on_bright_red(&self) -> Painted<&T>
§fn on_bright_green(&self) -> Painted<&T>
fn on_bright_green(&self) -> Painted<&T>
§fn on_bright_yellow(&self) -> Painted<&T>
fn on_bright_yellow(&self) -> Painted<&T>
§fn on_bright_blue(&self) -> Painted<&T>
fn on_bright_blue(&self) -> Painted<&T>
§fn on_bright_magenta(&self) -> Painted<&T>
fn on_bright_magenta(&self) -> Painted<&T>
§fn on_bright_cyan(&self) -> Painted<&T>
fn on_bright_cyan(&self) -> Painted<&T>
§fn on_bright_white(&self) -> Painted<&T>
fn on_bright_white(&self) -> Painted<&T>
§fn attr(&self, value: Attribute) -> Painted<&T>
fn attr(&self, value: Attribute) -> Painted<&T>
Enables the styling [Attribute] value.
This method should be used rarely. Instead, prefer to use
attribute-specific builder methods like bold() and
underline(), which have the same functionality
but are pithier.
§Example
Make text bold using attr():
use yansi::{Paint, Attribute};
painted.attr(Attribute::Bold);Make text bold using using bold().
use yansi::Paint;
painted.bold();§fn rapid_blink(&self) -> Painted<&T>
fn rapid_blink(&self) -> Painted<&T>
§fn quirk(&self, value: Quirk) -> Painted<&T>
fn quirk(&self, value: Quirk) -> Painted<&T>
Enables the yansi [Quirk] value.
This method should be used rarely. Instead, prefer to use quirk-specific
builder methods like mask() and
wrap(), which have the same functionality but are
pithier.
§Example
Enable wrapping using .quirk():
use yansi::{Paint, Quirk};
painted.quirk(Quirk::Wrap);Enable wrapping using wrap().
use yansi::Paint;
painted.wrap();§fn clear(&self) -> Painted<&T>
👎Deprecated since 1.0.1: renamed to resetting() due to conflicts with Vec::clear().
The clear() method will be removed in a future release.
fn clear(&self) -> Painted<&T>
renamed to resetting() due to conflicts with Vec::clear().
The clear() method will be removed in a future release.
§fn whenever(&self, value: Condition) -> Painted<&T>
fn whenever(&self, value: Condition) -> Painted<&T>
Conditionally enable styling based on whether the [Condition] value
applies. Replaces any previous condition.
See the crate level docs for more details.
§Example
Enable styling painted only when both stdout and stderr are TTYs:
use yansi::{Paint, Condition};
painted.red().on_yellow().whenever(Condition::STDOUTERR_ARE_TTY);§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
§impl<'p, T> Seq<'p, T> for Twhere
T: Clone,
impl<'p, T> Seq<'p, T> for Twhere
T: Clone,
§type Iter<'a> = Once<&'a T>
where
T: 'a
type Iter<'a> = Once<&'a T> where T: 'a
§fn contains(&self, val: &T) -> boolwhere
T: PartialEq,
fn contains(&self, val: &T) -> boolwhere
T: PartialEq,
§fn to_maybe_ref<'b>(item: <T as Seq<'p, T>>::Item<'b>) -> Maybe<T, &'p T>where
'p: 'b,
fn to_maybe_ref<'b>(item: <T as Seq<'p, T>>::Item<'b>) -> Maybe<T, &'p T>where
'p: 'b,
MaybeRef].