pub struct CubeState {
pub cp: [u8; 8],
pub co: [i8; 8],
pub ep: [u8; 12],
pub eo: [i8; 12],
}Expand description
The underlying struct for representing a configuration of the Rubik’s Cube.
Fields§
§cp: [u8; 8]§co: [i8; 8]§ep: [u8; 12]§eo: [i8; 12]Implementations§
Source§impl CubeState
impl CubeState
Sourcepub fn apply_move_instance(&self, m: &MoveInstance) -> Self
pub fn apply_move_instance(&self, m: &MoveInstance) -> Self
Applies a move to a Rubik’s Cube configuration.
Sourcepub fn apply_move_instances(&self, moves: &MoveSequence) -> Self
pub fn apply_move_instances(&self, moves: &MoveSequence) -> Self
Applies a sequence of moves, in order to a Rubik’s Cube configuration.
Trait Implementations§
impl Eq for CubeState
impl StructuralPartialEq for CubeState
Auto Trait Implementations§
impl Freeze for CubeState
impl RefUnwindSafe for CubeState
impl Send for CubeState
impl Sync for CubeState
impl Unpin for CubeState
impl UnwindSafe for CubeState
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.