pub struct PositionChange {
pub futu_symbol: Option<String>,
pub exchange: Option<String>,
pub long_short: Option<String>,
pub buy_quantity: Option<String>,
pub buy_cost: Option<String>,
pub sell_quantity: Option<String>,
pub sell_income: Option<String>,
pub settle_date: Option<u32>,
pub currency: Option<String>,
}Expand description
持仓变动
Fields§
§futu_symbol: Option<String>股票代码,比如BABA
exchange: Option<String>交易所
long_short: Option<String>多空类型,LONG为多,SHORT为空
buy_quantity: Option<String>买入数量
buy_cost: Option<String>买入支出
sell_quantity: Option<String>卖出数量
sell_income: Option<String>卖出收入
settle_date: Option<u32>交收日,立即交收填0,不确定交收填99999999
currency: Option<String>数字货币的币对,必填,否则无法区分buy_cost和sell_income,资产会将。目前可交易币对的币种有USD、SGD、JPY
Implementations§
Source§impl PositionChange
impl PositionChange
Sourcepub fn futu_symbol(&self) -> &str
pub fn futu_symbol(&self) -> &str
Returns the value of futu_symbol, or the default value if futu_symbol is unset.
Sourcepub fn exchange(&self) -> &str
pub fn exchange(&self) -> &str
Returns the value of exchange, or the default value if exchange is unset.
Sourcepub fn long_short(&self) -> &str
pub fn long_short(&self) -> &str
Returns the value of long_short, or the default value if long_short is unset.
Sourcepub fn buy_quantity(&self) -> &str
pub fn buy_quantity(&self) -> &str
Returns the value of buy_quantity, or the default value if buy_quantity is unset.
Sourcepub fn buy_cost(&self) -> &str
pub fn buy_cost(&self) -> &str
Returns the value of buy_cost, or the default value if buy_cost is unset.
Sourcepub fn sell_quantity(&self) -> &str
pub fn sell_quantity(&self) -> &str
Returns the value of sell_quantity, or the default value if sell_quantity is unset.
Sourcepub fn sell_income(&self) -> &str
pub fn sell_income(&self) -> &str
Returns the value of sell_income, or the default value if sell_income is unset.
Sourcepub fn settle_date(&self) -> u32
pub fn settle_date(&self) -> u32
Returns the value of settle_date, or the default value if settle_date is unset.
Trait Implementations§
Source§impl Clone for PositionChange
impl Clone for PositionChange
Source§fn clone(&self) -> PositionChange
fn clone(&self) -> PositionChange
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PositionChange
impl Debug for PositionChange
Source§impl Default for PositionChange
impl Default for PositionChange
Source§impl Hash for PositionChange
impl Hash for PositionChange
Source§impl Message for PositionChange
impl Message for PositionChange
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.Source§impl PartialEq for PositionChange
impl PartialEq for PositionChange
impl Eq for PositionChange
impl StructuralPartialEq for PositionChange
Auto Trait Implementations§
impl Freeze for PositionChange
impl RefUnwindSafe for PositionChange
impl Send for PositionChange
impl Sync for PositionChange
impl Unpin for PositionChange
impl UnsafeUnpin for PositionChange
impl UnwindSafe for PositionChange
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.