Struct spacetimedb_lib::VersionTuple
source · pub struct VersionTuple {
pub major: u16,
pub minor: u16,
}Fields§
§major: u16Breaking change; different major versions are not at all compatible with each other.
minor: u16Non-breaking change; a host can run a module that requests an older minor version than the host implements, but not the other way around
Implementations§
source§impl VersionTuple
impl VersionTuple
pub const fn new(major: u16, minor: u16) -> Self
pub const fn eq(self, other: Self) -> bool
sourcepub const fn supports(self, module_version: VersionTuple) -> bool
pub const fn supports(self, module_version: VersionTuple) -> bool
Checks if a host implementing this version can run a module that expects module_version
pub const fn from_u32(v: u32) -> Self
pub const fn to_u32(self) -> u32
Trait Implementations§
source§impl Clone for VersionTuple
impl Clone for VersionTuple
source§fn clone(&self) -> VersionTuple
fn clone(&self) -> VersionTuple
Returns a copy 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 VersionTuple
impl Debug for VersionTuple
source§impl Display for VersionTuple
impl Display for VersionTuple
source§impl PartialEq for VersionTuple
impl PartialEq for VersionTuple
source§fn eq(&self, other: &VersionTuple) -> bool
fn eq(&self, other: &VersionTuple) -> bool
This method tests for
self and other values to be equal, and is used
by ==.impl Copy for VersionTuple
impl Eq for VersionTuple
impl StructuralEq for VersionTuple
impl StructuralPartialEq for VersionTuple
Auto Trait Implementations§
impl RefUnwindSafe for VersionTuple
impl Send for VersionTuple
impl Sync for VersionTuple
impl Unpin for VersionTuple
impl UnwindSafe for VersionTuple
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