#[allow(unused_imports)]
use serde_json::Value;
#[derive(Debug, Serialize, Deserialize)]
pub struct StocksInnerContracts {
#[serde(rename = "conid")]
conid: Option<i32>,
#[serde(rename = "exchange")]
exchange: Option<String>
}
impl StocksInnerContracts {
pub fn new() -> StocksInnerContracts {
StocksInnerContracts {
conid: None,
exchange: None
}
}
pub fn set_conid(&mut self, conid: i32) {
self.conid = Some(conid);
}
pub fn with_conid(mut self, conid: i32) -> StocksInnerContracts {
self.conid = Some(conid);
self
}
pub fn conid(&self) -> Option<&i32> {
self.conid.as_ref()
}
pub fn reset_conid(&mut self) {
self.conid = None;
}
pub fn set_exchange(&mut self, exchange: String) {
self.exchange = Some(exchange);
}
pub fn with_exchange(mut self, exchange: String) -> StocksInnerContracts {
self.exchange = Some(exchange);
self
}
pub fn exchange(&self) -> Option<&String> {
self.exchange.as_ref()
}
pub fn reset_exchange(&mut self) {
self.exchange = None;
}
}