Skip to main content

openapi_service_fabric/models/
application_description.rs

1/*
2 * Service Fabric Client APIs
3 *
4 * Service Fabric REST Client APIs allows management of Service Fabric clusters, applications and services.
5 *
6 * The version of the OpenAPI document: 8.2
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// ApplicationDescription : Describes a Service Fabric application.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct ApplicationDescription {
17    /// The name of the application, including the 'fabric:' URI scheme.
18    #[serde(rename = "Name")]
19    pub name: String,
20    /// The application type name as defined in the application manifest.
21    #[serde(rename = "TypeName")]
22    pub type_name: String,
23    /// The version of the application type as defined in the application manifest.
24    #[serde(rename = "TypeVersion")]
25    pub type_version: String,
26    /// List of application parameters with overridden values from their default values specified in the application manifest.
27    #[serde(rename = "ParameterList", skip_serializing_if = "Option::is_none")]
28    pub parameter_list: Option<Vec<models::ApplicationParameter>>,
29    #[serde(
30        rename = "ApplicationCapacity",
31        skip_serializing_if = "Option::is_none"
32    )]
33    pub application_capacity: Option<Box<models::ApplicationCapacityDescription>>,
34    #[serde(
35        rename = "ManagedApplicationIdentity",
36        skip_serializing_if = "Option::is_none"
37    )]
38    pub managed_application_identity: Option<Box<models::ManagedApplicationIdentityDescription>>,
39}
40
41impl ApplicationDescription {
42    /// Describes a Service Fabric application.
43    pub fn new(name: String, type_name: String, type_version: String) -> ApplicationDescription {
44        ApplicationDescription {
45            name,
46            type_name,
47            type_version,
48            parameter_list: None,
49            application_capacity: None,
50            managed_application_identity: None,
51        }
52    }
53}