Contract

Struct Contract 

Source
pub struct Contract { /* private fields */ }

Implementations§

Source§

impl Contract

Source

pub fn new() -> Contract

Contains all details of the contract, including rules you can use when placing orders

Source

pub fn set_category(&mut self, category: String)

Source

pub fn with_category(self, category: String) -> Contract

Source

pub fn category(&self) -> Option<&String>

Source

pub fn reset_category(&mut self)

Source

pub fn set_company_name(&mut self, company_name: String)

Source

pub fn with_company_name(self, company_name: String) -> Contract

Source

pub fn company_name(&self) -> Option<&String>

Source

pub fn reset_company_name(&mut self)

Source

pub fn set_con_id(&mut self, con_id: String)

Source

pub fn with_con_id(self, con_id: String) -> Contract

Source

pub fn con_id(&self) -> Option<&String>

Source

pub fn reset_con_id(&mut self)

Source

pub fn set_currency(&mut self, currency: String)

Source

pub fn with_currency(self, currency: String) -> Contract

Source

pub fn currency(&self) -> Option<&String>

Source

pub fn reset_currency(&mut self)

Source

pub fn set_exchange(&mut self, exchange: String)

Source

pub fn with_exchange(self, exchange: String) -> Contract

Source

pub fn exchange(&self) -> Option<&String>

Source

pub fn reset_exchange(&mut self)

Source

pub fn set_industry(&mut self, industry: String)

Source

pub fn with_industry(self, industry: String) -> Contract

Source

pub fn industry(&self) -> Option<&String>

Source

pub fn reset_industry(&mut self)

Source

pub fn set_instrument_type(&mut self, instrument_type: String)

Source

pub fn with_instrument_type(self, instrument_type: String) -> Contract

Source

pub fn instrument_type(&self) -> Option<&String>

Source

pub fn reset_instrument_type(&mut self)

Source

pub fn set_local_symbol(&mut self, local_symbol: String)

Source

pub fn with_local_symbol(self, local_symbol: String) -> Contract

Source

pub fn local_symbol(&self) -> Option<&String>

Source

pub fn reset_local_symbol(&mut self)

Source

pub fn set_r_t_h(&mut self, r_t_h: bool)

Source

pub fn with_r_t_h(self, r_t_h: bool) -> Contract

Source

pub fn r_t_h(&self) -> Option<&bool>

Source

pub fn reset_r_t_h(&mut self)

Source

pub fn set_rules(&mut self, rules: ContractRules)

Source

pub fn with_rules(self, rules: ContractRules) -> Contract

Source

pub fn rules(&self) -> Option<&ContractRules>

Source

pub fn reset_rules(&mut self)

Trait Implementations§

Source§

impl Debug for Contract

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for Contract

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Serialize for Contract

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,