Struct tskit::PopulationId
source · #[repr(transparent)]pub struct PopulationId(_);
Expand description
A population ID
This is an integer referring to a row of an PopulationTable
.
The features for this type follow the same pattern as for NodeId
Implementations
sourceimpl PopulationId
impl PopulationId
Trait Implementations
sourceimpl Clone for PopulationId
impl Clone for PopulationId
sourcefn clone(&self) -> PopulationId
fn clone(&self) -> PopulationId
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for PopulationId
impl Debug for PopulationId
sourceimpl Display for PopulationId
impl Display for PopulationId
sourceimpl From<PopulationId> for tsk_id_t
impl From<PopulationId> for tsk_id_t
sourcefn from(value: PopulationId) -> Self
fn from(value: PopulationId) -> Self
Converts to this type from the input type.
sourceimpl From<i32> for PopulationId
impl From<i32> for PopulationId
sourceimpl Hash for PopulationId
impl Hash for PopulationId
sourceimpl Ord for PopulationId
impl Ord for PopulationId
sourcefn cmp(&self, other: &PopulationId) -> Ordering
fn cmp(&self, other: &PopulationId) -> Ordering
1.21.0 · sourcefn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 · sourcefn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
1.50.0 · sourcefn clamp(self, min: Self, max: Self) -> Selfwhere
Self: Sized + PartialOrd<Self>,
fn clamp(self, min: Self, max: Self) -> Selfwhere
Self: Sized + PartialOrd<Self>,
Restrict a value to a certain interval. Read more
sourceimpl PartialEq<PopulationId> for PopulationId
impl PartialEq<PopulationId> for PopulationId
sourcefn eq(&self, other: &PopulationId) -> bool
fn eq(&self, other: &PopulationId) -> bool
sourceimpl PartialEq<PopulationId> for SizeType
impl PartialEq<PopulationId> for SizeType
sourcefn eq(&self, other: &PopulationId) -> bool
fn eq(&self, other: &PopulationId) -> bool
sourceimpl PartialEq<PopulationId> for tsk_id_t
impl PartialEq<PopulationId> for tsk_id_t
sourcefn eq(&self, other: &PopulationId) -> bool
fn eq(&self, other: &PopulationId) -> bool
sourceimpl PartialOrd<PopulationId> for PopulationId
impl PartialOrd<PopulationId> for PopulationId
sourcefn partial_cmp(&self, other: &PopulationId) -> Option<Ordering>
fn partial_cmp(&self, other: &PopulationId) -> Option<Ordering>
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresourceimpl PartialOrd<PopulationId> for SizeType
impl PartialOrd<PopulationId> for SizeType
sourcefn partial_cmp(&self, other: &PopulationId) -> Option<Ordering>
fn partial_cmp(&self, other: &PopulationId) -> Option<Ordering>
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresourceimpl PartialOrd<PopulationId> for tsk_id_t
impl PartialOrd<PopulationId> for tsk_id_t
sourcefn partial_cmp(&self, other: &PopulationId) -> Option<Ordering>
fn partial_cmp(&self, other: &PopulationId) -> Option<Ordering>
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresourceimpl PartialOrd<SizeType> for PopulationId
impl PartialOrd<SizeType> for PopulationId
sourcefn partial_cmp(&self, other: &SizeType) -> Option<Ordering>
fn partial_cmp(&self, other: &SizeType) -> Option<Ordering>
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresourceimpl PartialOrd<i32> for PopulationId
impl PartialOrd<i32> for PopulationId
sourcefn partial_cmp(&self, other: &tsk_id_t) -> Option<Ordering>
fn partial_cmp(&self, other: &tsk_id_t) -> Option<Ordering>
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresourceimpl TryFrom<PopulationId> for SizeType
impl TryFrom<PopulationId> for SizeType
type Error = TskitError
type Error = TskitError
The type returned in the event of a conversion error.
sourcefn try_from(value: PopulationId) -> Result<Self, Self::Error>
fn try_from(value: PopulationId) -> Result<Self, Self::Error>
Performs the conversion.
sourceimpl TryFrom<PopulationId> for usize
impl TryFrom<PopulationId> for usize
type Error = TskitError
type Error = TskitError
The type returned in the event of a conversion error.
sourcefn try_from(value: PopulationId) -> Result<Self, Self::Error>
fn try_from(value: PopulationId) -> Result<Self, Self::Error>
Performs the conversion.
impl Copy for PopulationId
impl Eq for PopulationId
impl StructuralEq for PopulationId
impl StructuralPartialEq for PopulationId
Auto Trait Implementations
impl RefUnwindSafe for PopulationId
impl Send for PopulationId
impl Sync for PopulationId
impl Unpin for PopulationId
impl UnwindSafe for PopulationId
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more