Skip to main content

nautobot_openapi/models/
patched_cloud_network_prefix_assignment_request.rs

1/*
2 * API Documentation
3 *
4 * Source of truth and network automation platform
5 *
6 * The version of the OpenAPI document: 3.1.0 (3.1)
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11/// PatchedCloudNetworkPrefixAssignmentRequest : Extends the built-in ModelSerializer to enforce calling full_clean() on a copy of the associated instance during validation. (DRF does not do this by default; see <https://github.com/encode/django-rest-framework/issues/3144>)
12
13#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
14pub struct PatchedCloudNetworkPrefixAssignmentRequest {
15    #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
16    pub id: Option<uuid::Uuid>,
17    #[serde(rename = "cloud_network", skip_serializing_if = "Option::is_none")]
18    pub cloud_network:
19        Option<Box<crate::models::ApprovalWorkflowStageResponseApprovalWorkflowStage>>,
20    #[serde(rename = "prefix", skip_serializing_if = "Option::is_none")]
21    pub prefix: Option<Box<crate::models::ApprovalWorkflowStageResponseApprovalWorkflowStage>>,
22}
23
24impl PatchedCloudNetworkPrefixAssignmentRequest {
25    /// Extends the built-in ModelSerializer to enforce calling full_clean() on a copy of the associated instance during validation. (DRF does not do this by default; see <https://github.com/encode/django-rest-framework/issues/3144>)
26    pub fn new() -> PatchedCloudNetworkPrefixAssignmentRequest {
27        PatchedCloudNetworkPrefixAssignmentRequest {
28            id: None,
29            cloud_network: None,
30            prefix: None,
31        }
32    }
33}