stcloud 0.5.0

Client package for talking to Sematext Cloud.
Documentation
/* 
 * Sematext Cloud API
 *
 * API Explorer provides access and documentation for Sematext REST API. The REST API requires the API Key to be sent as part of `Authorization` header. E.g.: `Authorization : apiKey e5f18450-205a-48eb-8589-7d49edaea813`.
 *
 * OpenAPI spec version: v3
 * 
 * Generated by: https://github.com/swagger-api/swagger-codegen.git
 */
#![allow(unused_imports)]

use serde_json::Value;
use bigdecimal::BigDecimal;
use chrono::{Date, NaiveDateTime, NaiveDate, DateTime, FixedOffset, Utc};

use crate::models::*;
use crate::date_serializer;
use crate::date_serializer_opt;
use crate::serialize_quoted_numbers;
use crate::serialize_quoted_numbers_opt;
//Uncomment this to deal with limited rfc support on server side
//use crate::datetime_serializer::*;

#[derive(Debug, Serialize, Deserialize, PartialEq, Clone)]
pub struct DailyDto {
  #[serde(rename = "day")]
  #[serde(default)]
  day: Option<i64>, 
  #[serde(rename = "failed")]
  #[serde(default)]
  failed: Option<i64>, 
  #[serde(rename = "ingestedCount")]
  #[serde(default)]
  ingested_count: Option<i64>, 
  #[serde(rename = "ingestedVolume")]
  #[serde(default)]
  ingested_volume: Option<i64>, 
  #[serde(rename = "storedCount")]
  #[serde(default)]
  stored_count: Option<i64>, 
  #[serde(rename = "storedVolume")]
  #[serde(default)]
  stored_volume: Option<i64> 
}

impl DailyDto {
  pub fn new() -> DailyDto {
    DailyDto {
      day: None,
      failed: None,
      ingested_count: None,
      ingested_volume: None,
      stored_count: None,
      stored_volume: None
    }
  }

  pub fn set_day(&mut self, day: i64) {
    self.day = Some(day);
  }

  pub fn with_day(mut self, day: i64) -> DailyDto {
    self.day = Some(day);
    self
  }

  pub fn day(&self) -> Option<&i64> {
    self.day.as_ref()
  }

  pub fn reset_day(&mut self) {
    self.day = None;
  }

  pub fn set_failed(&mut self, failed: i64) {
    self.failed = Some(failed);
  }

  pub fn with_failed(mut self, failed: i64) -> DailyDto {
    self.failed = Some(failed);
    self
  }

  pub fn failed(&self) -> Option<&i64> {
    self.failed.as_ref()
  }

  pub fn reset_failed(&mut self) {
    self.failed = None;
  }

  pub fn set_ingested_count(&mut self, ingested_count: i64) {
    self.ingested_count = Some(ingested_count);
  }

  pub fn with_ingested_count(mut self, ingested_count: i64) -> DailyDto {
    self.ingested_count = Some(ingested_count);
    self
  }

  pub fn ingested_count(&self) -> Option<&i64> {
    self.ingested_count.as_ref()
  }

  pub fn reset_ingested_count(&mut self) {
    self.ingested_count = None;
  }

  pub fn set_ingested_volume(&mut self, ingested_volume: i64) {
    self.ingested_volume = Some(ingested_volume);
  }

  pub fn with_ingested_volume(mut self, ingested_volume: i64) -> DailyDto {
    self.ingested_volume = Some(ingested_volume);
    self
  }

  pub fn ingested_volume(&self) -> Option<&i64> {
    self.ingested_volume.as_ref()
  }

  pub fn reset_ingested_volume(&mut self) {
    self.ingested_volume = None;
  }

  pub fn set_stored_count(&mut self, stored_count: i64) {
    self.stored_count = Some(stored_count);
  }

  pub fn with_stored_count(mut self, stored_count: i64) -> DailyDto {
    self.stored_count = Some(stored_count);
    self
  }

  pub fn stored_count(&self) -> Option<&i64> {
    self.stored_count.as_ref()
  }

  pub fn reset_stored_count(&mut self) {
    self.stored_count = None;
  }

  pub fn set_stored_volume(&mut self, stored_volume: i64) {
    self.stored_volume = Some(stored_volume);
  }

  pub fn with_stored_volume(mut self, stored_volume: i64) -> DailyDto {
    self.stored_volume = Some(stored_volume);
    self
  }

  pub fn stored_volume(&self) -> Option<&i64> {
    self.stored_volume.as_ref()
  }

  pub fn reset_stored_volume(&mut self) {
    self.stored_volume = None;
  }


  pub fn validate(&self) {
  }

}