/*
 * Websocket Subscription Schemas
 *
 * Schema definitions Websocket API subscriptions for Thalex exchange.
 *
 * The version of the OpenAPI document: 1.0.0
 *
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct RfqLegsInner {
    #[serde(rename = "instrument_name")]
    pub instrument_name: String,
    /// Quantity for this leg. May be negative.
    #[serde(rename = "quantity")]
    pub quantity: rust_decimal::Decimal,
    /// Quantity for fee calculations. Anywhere between 0 and abs(quantity).
    #[serde(rename = "fee_quantity")]
    pub fee_quantity: rust_decimal::Decimal,
}

impl RfqLegsInner {
    pub fn new(
        instrument_name: String,
        quantity: rust_decimal::Decimal,
        fee_quantity: rust_decimal::Decimal,
    ) -> RfqLegsInner {
        RfqLegsInner {
            instrument_name,
            quantity,
            fee_quantity,
        }
    }
}
