pub struct BuildInfo {
    pub version: &'static str,
    pub sha: &'static str,
    pub time: &'static str,
}
Expand description

Build information.

Fields§

§version: &'static str

The version number of the build.

§sha: &'static str

The 40-character SHA-1 hash identifying the Git commit of the build.

§time: &'static str

The time of the build in UTC as an ISO 8601-compliant string.

Implementations§

Constructs a human-readable version string.

Returns the version as a rich semantic version.

This method is only available when the semver feature is active.

Panics

Panics if the version field is not a valid semantic version.

Returns the version as an integer along the lines of Pg’s server_version_num

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
This method tests for self and other values to be equal, and is used by ==.
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.