puddle-farm-api-client_openapi_client 1.1.0

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
Documentation
/*
 * puddle.farm API
 *
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: v1
 * 
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct CalcRatingResponse {
    /// Player A's new rating after the match
    #[serde(rename = "rating_a_new", skip_serializing_if = "Option::is_none")]
    pub rating_a_new: Option<f32>,
    /// Player A's new drift after the match
    #[serde(rename = "drift_a_new", skip_serializing_if = "Option::is_none")]
    pub drift_a_new: Option<f32>,
    /// Player B's new rating after the match
    #[serde(rename = "rating_b_new", skip_serializing_if = "Option::is_none")]
    pub rating_b_new: Option<f32>,
    /// Player B's new drift after the match
    #[serde(rename = "drift_b_new", skip_serializing_if = "Option::is_none")]
    pub drift_b_new: Option<f32>,
    /// Probability that Player A wins the match
    #[serde(rename = "win_prob", skip_serializing_if = "Option::is_none")]
    pub win_prob: Option<f32>,
}

impl CalcRatingResponse {
    pub fn new() -> CalcRatingResponse {
        CalcRatingResponse {
            rating_a_new: None,
            drift_a_new: None,
            rating_b_new: None,
            drift_b_new: None,
            win_prob: None,
        }
    }
}