pub struct FossilOccurrence { /* private fields */ }Implementations§
Source§impl FossilOccurrence
impl FossilOccurrence
Sourcepub fn new(
formation: Option<String>,
time_label: Option<String>,
) -> Result<Self, FossilOccurrenceError>
pub fn new( formation: Option<String>, time_label: Option<String>, ) -> Result<Self, FossilOccurrenceError>
Creates a fossil occurrence from at least one formation or time label.
§Errors
Returns FossilOccurrenceError::EmptyFormation when the formation is empty.
Returns FossilOccurrenceError::EmptyTimeLabel when the time label is empty.
Returns FossilOccurrenceError::MissingReference when both values are absent.
pub fn formation(&self) -> Option<&str>
pub fn time_label(&self) -> Option<&str>
Trait Implementations§
Source§impl Clone for FossilOccurrence
impl Clone for FossilOccurrence
Source§fn clone(&self) -> FossilOccurrence
fn clone(&self) -> FossilOccurrence
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 Debug for FossilOccurrence
impl Debug for FossilOccurrence
Source§impl Display for FossilOccurrence
impl Display for FossilOccurrence
Source§impl Hash for FossilOccurrence
impl Hash for FossilOccurrence
Source§impl Ord for FossilOccurrence
impl Ord for FossilOccurrence
Source§fn cmp(&self, other: &FossilOccurrence) -> Ordering
fn cmp(&self, other: &FossilOccurrence) -> Ordering
1.21.0 · Source§fn 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
Source§impl PartialEq for FossilOccurrence
impl PartialEq for FossilOccurrence
Source§impl PartialOrd for FossilOccurrence
impl PartialOrd for FossilOccurrence
impl Eq for FossilOccurrence
impl StructuralPartialEq for FossilOccurrence
Auto Trait Implementations§
impl Freeze for FossilOccurrence
impl RefUnwindSafe for FossilOccurrence
impl Send for FossilOccurrence
impl Sync for FossilOccurrence
impl Unpin for FossilOccurrence
impl UnsafeUnpin for FossilOccurrence
impl UnwindSafe for FossilOccurrence
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