jira_api_v2/models/
error_collection.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/// ErrorCollection : Error messages from an operation.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct ErrorCollection {
17    /// The list of error messages produced by this operation. For example, \"input parameter 'key' must be provided\"
18    #[serde(rename = "errorMessages", skip_serializing_if = "Option::is_none")]
19    pub error_messages: Option<Vec<String>>,
20    /// The list of errors by parameter returned by the operation. For example,\"projectKey\": \"Project keys must start with an uppercase letter, followed by one or more uppercase alphanumeric characters.\"
21    #[serde(rename = "errors", skip_serializing_if = "Option::is_none")]
22    pub errors: Option<std::collections::HashMap<String, String>>,
23    #[serde(rename = "status", skip_serializing_if = "Option::is_none")]
24    pub status: Option<i32>,
25}
26
27impl ErrorCollection {
28    /// Error messages from an operation.
29    pub fn new() -> ErrorCollection {
30        ErrorCollection {
31            error_messages: None,
32            errors: None,
33            status: None,
34        }
35    }
36}
37