pub struct Version {
pub major: u32,
pub minor: u32,
pub release: u32,
pub extra: Option<String>,
}
Expand description
Represents a PHP version.
Fields§
§major: u32
§minor: u32
§release: u32
§extra: Option<String>
Trait Implementations§
Source§impl Display for Version
Display Version
.
impl Display for Version
Display Version
.
Example:
use php_discovery::build::Version;
let v = Version {
major: 8,
minor: 2,
release: 0,
extra: Some("RC6".to_string())
};
assert_eq!("8.2.0RC6", v.to_string());
let v = Version {
major: 7,
minor: 4,
release: 11,
extra: None
};
assert_eq!("7.4.11", v.to_string());
impl Eq for Version
impl StructuralPartialEq for Version
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