pub struct Preference<SelectionT> {
pub selector: Selector<SelectionT>,
pub weight: Weight,
}
Expand description
Weighted preference.
Fields§
§selector: Selector<SelectionT>
Selector.
weight: Weight
Weight.
Implementations§
Trait Implementations§
Source§impl<SelectionT: Clone> Clone for Preference<SelectionT>
impl<SelectionT: Clone> Clone for Preference<SelectionT>
Source§fn clone(&self) -> Preference<SelectionT>
fn clone(&self) -> Preference<SelectionT>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl<SelectionT: Debug> Debug for Preference<SelectionT>
impl<SelectionT: Debug> Debug for Preference<SelectionT>
Auto Trait Implementations§
impl<SelectionT> Freeze for Preference<SelectionT>where
SelectionT: Freeze,
impl<SelectionT> RefUnwindSafe for Preference<SelectionT>where
SelectionT: RefUnwindSafe,
impl<SelectionT> Send for Preference<SelectionT>where
SelectionT: Send,
impl<SelectionT> Sync for Preference<SelectionT>where
SelectionT: Sync,
impl<SelectionT> Unpin for Preference<SelectionT>where
SelectionT: Unpin,
impl<SelectionT> UnwindSafe for Preference<SelectionT>where
SelectionT: UnwindSafe,
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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