Struct semver_rs::Version [−][src]
pub struct Version {
pub major: i64,
pub minor: i64,
pub patch: i64,
pub prerelease: Option<Vec<String>>,
// some fields omitted
}
Expand description
A version
is described by the v2.0.0
specification found at semver.
A leading =
or v
character is stripped off and ignored.
Fields
major: i64
minor: i64
patch: i64
prerelease: Option<Vec<String>>
Implementations
Constructs a version from its already parsed parts, e.g. Version::from_parts(1, 2, 3, None)
.
Trait Implementations
This method returns an ordering between self
and other
values if one exists. Read more
This method tests less than (for self
and other
) and is used by the <
operator. Read more
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
Auto Trait Implementations
impl RefUnwindSafe for Version
impl UnwindSafe for Version
Blanket Implementations
Mutably borrows from an owned value. Read more