pub struct Version {
pub major: u32,
pub minor: u32,
pub patch: u32,
pub release_date: u32,
pub ffi_api: u32,
pub string: String,
}Expand description
Information about the library version
Fields§
§major: u32The major version of the library
minor: u32The minor version of the library
patch: u32The patch version of the library
release_date: u32The release date of the library, as YYYYMMDD, for example 2.7.0 has value 20180702. Will be 0 for unreleased versions.
ffi_api: u32The version of the FFI API, as a YYYYMMDD field.
string: StringA free-form string describing the library version
Implementations§
Source§impl Version
impl Version
Sourcepub fn at_least(&self, major: u32, minor: u32) -> bool
pub fn at_least(&self, major: u32, minor: u32) -> bool
Return true if the current version is at least as high as the major and minor numbers passed as arguments
Sourcepub fn supports_version(version: u32) -> bool
pub fn supports_version(version: u32) -> bool
Return true if the specified API version is supported by this version of the library.
§Examples
assert_eq!(botan::Version::supports_version(42), false);
assert_eq!(botan::Version::supports_version(20180713), true);Trait Implementations§
Auto Trait Implementations§
impl Freeze for Version
impl RefUnwindSafe for Version
impl Send for Version
impl Sync for Version
impl Unpin for Version
impl UnwindSafe for Version
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