pub struct ListPermuteMove<S, V> { /* private fields */ }Implementations§
Source§impl<S, V> ListPermuteMove<S, V>
impl<S, V> ListPermuteMove<S, V>
pub fn new( entity_index: usize, start: usize, end: usize, permutation: SmallVec<[usize; 8]>, list_len: fn(&S, usize) -> usize, list_get: fn(&S, usize, usize) -> Option<V>, sublist_remove: fn(&mut S, usize, usize, usize) -> Vec<V>, sublist_insert: fn(&mut S, usize, usize, Vec<V>), variable_name: &'static str, descriptor_index: usize, ) -> Self
pub fn entity_index(&self) -> usize
pub fn start(&self) -> usize
pub fn end(&self) -> usize
pub fn permutation(&self) -> &[usize]
Trait Implementations§
Source§impl<S, V> Clone for ListPermuteMove<S, V>
impl<S, V> Clone for ListPermuteMove<S, V>
Source§impl<S, V: Debug> Debug for ListPermuteMove<S, V>
impl<S, V: Debug> Debug for ListPermuteMove<S, V>
Source§impl<S, V> Move<S> for ListPermuteMove<S, V>
impl<S, V> Move<S> for ListPermuteMove<S, V>
type Undo = Vec<V>
fn is_doable<D: Director<S>>(&self, score_director: &D) -> bool
fn do_move<D: Director<S>>(&self, score_director: &mut D) -> Self::Undo
fn undo_move<D: Director<S>>(&self, score_director: &mut D, undo: Self::Undo)
fn descriptor_index(&self) -> usize
fn entity_indices(&self) -> &[usize]
fn variable_name(&self) -> &str
fn telemetry_label(&self) -> &'static str
fn tabu_signature<D: Director<S>>( &self, score_director: &D, ) -> MoveTabuSignature
fn requires_hard_improvement(&self) -> bool
fn requires_score_improvement(&self) -> bool
fn for_each_affected_entity( &self, visitor: &mut dyn FnMut(MoveAffectedEntity<'_>), )
Source§impl<S, V> MoveCursor<S, ListPermuteMove<S, V>> for ListPermuteMoveCursor<S, V>
impl<S, V> MoveCursor<S, ListPermuteMove<S, V>> for ListPermuteMoveCursor<S, V>
fn next_candidate(&mut self) -> Option<CandidateId>
fn candidate( &self, id: CandidateId, ) -> Option<MoveCandidateRef<'_, S, ListPermuteMove<S, V>>>
fn take_candidate(&mut self, id: CandidateId) -> ListPermuteMove<S, V>
fn selector_index(&self, _id: CandidateId) -> Option<usize>
Source§impl<S, V, ES> MoveSelector<S, ListPermuteMove<S, V>> for ListPermuteMoveSelector<S, V, ES>
impl<S, V, ES> MoveSelector<S, ListPermuteMove<S, V>> for ListPermuteMoveSelector<S, V, ES>
type Cursor<'a> = ListPermuteMoveCursor<S, V> where Self: 'a
fn open_cursor<'a, D: Director<S>>( &'a self, score_director: &D, ) -> Self::Cursor<'a>
fn open_cursor_with_context<'a, D: Director<S>>( &'a self, score_director: &D, context: MoveStreamContext, ) -> Self::Cursor<'a>
fn size<D: Director<S>>(&self, score_director: &D) -> usize
fn iter_moves<'a, D: Director<S>>( &'a self, score_director: &D, ) -> MoveSelectorIter<S, M, Self::Cursor<'a>> ⓘ
fn append_moves<D: Director<S>>( &self, score_director: &D, arena: &mut MoveArena<M>, )
fn is_never_ending(&self) -> bool
Auto Trait Implementations§
impl<S, V> Freeze for ListPermuteMove<S, V>
impl<S, V> RefUnwindSafe for ListPermuteMove<S, V>
impl<S, V> Send for ListPermuteMove<S, V>
impl<S, V> Sync for ListPermuteMove<S, V>
impl<S, V> Unpin for ListPermuteMove<S, V>
impl<S, V> UnsafeUnpin for ListPermuteMove<S, V>
impl<S, V> UnwindSafe for ListPermuteMove<S, V>
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<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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>
Converts
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>
Converts
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