jira_api_v2/models/
field_update_operation.rs

1/*
2 * The Jira Cloud platform REST API
3 *
4 * Jira Cloud platform REST API documentation
5 *
6 * The version of the OpenAPI document: 1001.0.0-SNAPSHOT
7 * Contact: ecosystem@atlassian.com
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// FieldUpdateOperation : Details of an operation to perform on a field.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct FieldUpdateOperation {
17    /// A map containing the name of a field and the value to add to it.
18    #[serde(rename = "add", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
19    pub add: Option<Option<serde_json::Value>>,
20    /// A map containing the name of a field and the value to set in it.
21    #[serde(rename = "set", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
22    pub set: Option<Option<serde_json::Value>>,
23    /// A map containing the name of a field and the value to removed from it.
24    #[serde(rename = "remove", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
25    pub remove: Option<Option<serde_json::Value>>,
26    /// A map containing the name of a field and the value to edit in it.
27    #[serde(rename = "edit", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
28    pub edit: Option<Option<serde_json::Value>>,
29}
30
31impl FieldUpdateOperation {
32    /// Details of an operation to perform on a field.
33    pub fn new() -> FieldUpdateOperation {
34        FieldUpdateOperation {
35            add: None,
36            set: None,
37            remove: None,
38            edit: None,
39        }
40    }
41}
42