Struct casper_types::SemVer
source · pub struct SemVer {
pub major: u32,
pub minor: u32,
pub patch: u32,
}
Expand description
A struct for semantic versioning.
Fields§
§major: u32
Major version.
minor: u32
Minor version.
patch: u32
Patch version.
Implementations§
Trait Implementations§
source§impl<'de> Deserialize<'de> for SemVer
impl<'de> Deserialize<'de> for SemVer
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Ord for SemVer
impl Ord for SemVer
source§impl PartialEq for SemVer
impl PartialEq for SemVer
source§impl PartialOrd for SemVer
impl PartialOrd for SemVer
1.0.0 · source§fn 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 moresource§impl ToBytes for SemVer
impl ToBytes for SemVer
source§fn serialized_length(&self) -> usize
fn serialized_length(&self) -> usize
Returns the length of the
Vec<u8>
which would be returned from a successful call to
to_bytes()
or into_bytes()
. The data is not actually serialized, so this call is
relatively cheap.impl Copy for SemVer
impl Eq for SemVer
impl StructuralEq for SemVer
impl StructuralPartialEq for SemVer
Auto Trait Implementations§
impl RefUnwindSafe for SemVer
impl Send for SemVer
impl Sync for SemVer
impl Unpin for SemVer
impl UnwindSafe for SemVer
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