opensearch-client 0.3.1

Strongly typed OpenSearch Client
Documentation
/*
 * opensearch-client
 *
 * Rust Client for OpenSearch
 *
 * The version of the OpenAPI document: 3.1.0
 * Contact: alberto.paro@gmail.com
 * Generated by Paro OpenAPI Generator
 */

use crate::common;
use serde::{Deserialize, Serialize};




#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct ResourceStats {
    #[serde(rename = "average")]
    pub average: common::ResourceStat,
    #[serde(rename = "thread_info")]
    pub thread_info: common::ThreadInfo,
    #[serde(rename = "min")]
    pub min: common::ResourceStat,
    #[serde(rename = "total")]
    pub total: common::ResourceStat,
    #[serde(rename = "max")]
    pub max: common::ResourceStat,
}

impl ResourceStats {
    
    pub fn new(average: common::ResourceStat, thread_info: common::ThreadInfo, min: common::ResourceStat, total: common::ResourceStat, max: common::ResourceStat) -> ResourceStats {
        ResourceStats {
            average,
            thread_info,
            min,
            total,
            max,
        }
    }
}