redfish-codegen 0.3.1

An unopinionated translation of the Redfish specification into Rust.
Documentation
// Generated by redfish-codegen. Do not modify.

use redfish_macros::IntoRedfishMessage;

/// This registry defines the license status and error messages.
#[derive(Clone, Debug, IntoRedfishMessage)]
#[message(crate::models::message::v1_1_2::Message)]
pub enum License {
    /// This message shall be used to indicate that a license has been installed.  Existing licenses may have been updated or otherwise affected by the installation.
    #[message(message = "The license '%1' has been installed.")]
    #[message(id = "License.1.0.2.LicenseInstalled")]
    #[message(severity = "crate::models::resource::Health::OK")]
    #[message(resolution = "None.")]
    LicenseInstalled(
        /// This argument shall contain the human readable identifier of the license.
        String,
    ),
    /// This message shall be used to indicate the number of days remaining on a license before expiration.
    #[message(message = "The license '%1' will expire in %2 days.")]
    #[message(id = "License.1.0.2.DaysBeforeExpiration")]
    #[message(severity = "crate::models::resource::Health::OK")]
    #[message(resolution = "None.")]
    DaysBeforeExpiration(
        /// This argument shall contain the human readable identifier of the license.
        String,
        /// This argument shall contain the number of days before the license expires.
        f64,
    ),
    /// This message shall be used to indicate that the license is not applicable to the target.
    #[message(message = "The license is not applicable to the target.")]
    #[message(id = "License.1.0.2.NotApplicableToTarget")]
    #[message(severity = "crate::models::resource::Health::Critical")]
    #[message(resolution = "Check the license compatibility or applicability to the specified target.")]
    NotApplicableToTarget,

    /// This message shall be used to indicate that one or more targets need to be specified with the license.
    #[message(message = "The license requires targets to be specified.")]
    #[message(id = "License.1.0.2.TargetsRequired")]
    #[message(severity = "crate::models::resource::Health::Critical")]
    #[message(resolution = "Add `AuthorizedDevices` to `Links` and resubmit the request.")]
    TargetsRequired,

    /// This message shall be used to indicate that the service failed to install the license.
    #[message(message = "Failed to install the license.  Reason: %1.")]
    #[message(id = "License.1.0.2.InstallFailed")]
    #[message(severity = "crate::models::resource::Health::Critical")]
    #[message(resolution = "None.")]
    InstallFailed(
        /// This argument shall contain the reason for the license installation failure.
        String,
    ),
    /// This message shall be used to indicate that a license has expired and its functionality has been disabled.
    #[message(message = "The license '%1' has expired.")]
    #[message(id = "License.1.0.2.Expired")]
    #[message(severity = "crate::models::resource::Health::Warning")]
    #[message(resolution = "None.")]
    Expired(
        /// This argument shall contain the human readable identifier of the license.
        String,
    ),
    /// This message shall be used to indicate that a license has expired and entered its grace period.
    #[message(message = "The license '%1' has expired, %2 day grace period before licensed functionality is disabled.")]
    #[message(id = "License.1.0.2.GracePeriod")]
    #[message(severity = "crate::models::resource::Health::Warning")]
    #[message(resolution = "None.")]
    GracePeriod(
        /// This argument shall contain the human readable identifier of the license.
        String,
        /// This argument shall contain the number day of grace period for the licensed functionality.
        f64,
    ),
    /// This message shall be used to indicate that the content of the license was not recognized, is corrupted, or is invalid.
    #[message(message = "The content of the license was not recognized, is corrupted, or is invalid.")]
    #[message(id = "License.1.0.2.InvalidLicense")]
    #[message(severity = "crate::models::resource::Health::Critical")]
    #[message(resolution = "Verify the license content is correct and resubmit the request.")]
    InvalidLicense,

}