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 serde::{Deserialize, Serialize};




#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct VariableWidthHistogramAggregation {  /// Specifies the number of individual documents that will be stored in memory on a shard before the initial bucketing algorithm is run.
  /// Defaults to `min(10 * shard_size, 50000)`.
    #[serde(rename = "initial_buffer", default, skip_serializing_if = "Option::is_none")]
    pub initial_buffer: Option<u32>,  /// The number of buckets that the coordinating node will request from each shard.
  /// Defaults to `buckets * 50`.
    #[serde(rename = "shard_size", default, skip_serializing_if = "Option::is_none")]
    pub shard_size: Option<u32>,  /// The path to a field or an array of paths. Some APIs support wildcards in the path, which allows you to select multiple fields.
    #[serde(rename = "field", default, skip_serializing_if = "Option::is_none")]
    pub field: Option<String>,  /// The target number of buckets.
    #[serde(rename = "buckets", default, skip_serializing_if = "Option::is_none")]
    pub buckets: Option<u32>,
}

impl VariableWidthHistogramAggregation {
    
    pub fn new() -> VariableWidthHistogramAggregation {
        VariableWidthHistogramAggregation {
            initial_buffer: None,
            shard_size: None,
            field: None,
            buckets: None,
        }
    }
}