Skip to main content

naurt_api/models/
final_destination_response.rs

1/*
2 * Naurt API
3 *
4 * OpenAPI specification for Naurt's APIs. 
5 *
6 * The version of the OpenAPI document: 0.1.2
7 * 
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// FinalDestinationResponse : A response from the API. The `responses` are in the same order as the original  `queries` from the request. 
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct FinalDestinationResponse {
17    #[serde(rename = "responses")]
18    pub responses: Vec<models::FinalDestinationHits>,
19    #[serde(rename = "logging", skip_serializing_if = "Option::is_none")]
20    pub logging: Option<Box<models::FinalDestinationLogging>>,
21    #[serde(rename = "version")]
22    pub version: String,
23    #[serde(rename = "request_id")]
24    pub request_id: uuid::Uuid,
25}
26
27impl FinalDestinationResponse {
28    /// A response from the API. The `responses` are in the same order as the original  `queries` from the request. 
29    pub fn new(responses: Vec<models::FinalDestinationHits>, version: String, request_id: uuid::Uuid) -> FinalDestinationResponse {
30        FinalDestinationResponse {
31            responses,
32            logging: None,
33            version,
34            request_id,
35        }
36    }
37}
38