pub struct EditionId {
pub family: &'static str,
pub year: u16,
pub month: u8,
pub version: u8,
}Expand description
The identifier of an edition, e.g. core2026.07.0.
The family names an independently versioned, additive group of members (core is the set
available to the default writer). For core, the date components record when the edition
freezes; that date is prospective while the edition is still a draft. Dates order editions
chronologically within a family; there is no ordering across families.
Fields§
§family: &'static strThe edition family, e.g. core.
year: u16Year in the edition date. For core, this is the freeze year.
month: u8Month in the edition date. For core, this is the freeze month.
version: u8Distinguishes editions with the same family, year, and month; normally 0.
Implementations§
Source§impl EditionId
impl EditionId
Sourcepub const fn new(
family: &'static str,
year: u16,
month: u8,
version: u8,
) -> Self
pub const fn new( family: &'static str, year: u16, month: u8, version: u8, ) -> Self
Create an edition identifier. Validated by EditionId::validate, which
test_harness::validate_edition exercises
per edition in unit tests.
Sourcepub fn is_at_or_before(&self, other: &EditionId) -> bool
pub fn is_at_or_before(&self, other: &EditionId) -> bool
Returns true if self is the same edition as other or an earlier edition of the
same family. Editions of different families are never ordered.
Sourcepub fn validate(&self) -> VortexResult<()>
pub fn validate(&self) -> VortexResult<()>
Validate the identifier’s form: a non-empty lowercase family, a four-digit year,
and a month in 01-12. Checked for every declared edition by
EditionSession::validate and per edition by
test_harness::validate_edition.
Trait Implementations§
impl Copy for EditionId
impl Eq for EditionId
Source§impl Ord for EditionId
impl Ord for EditionId
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialOrd for EditionId
impl PartialOrd for EditionId
impl StructuralPartialEq for EditionId
Auto Trait Implementations§
impl Freeze for EditionId
impl RefUnwindSafe for EditionId
impl Send for EditionId
impl Sync for EditionId
impl Unpin for EditionId
impl UnsafeUnpin for EditionId
impl UnwindSafe for EditionId
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.