pub struct AccFundInfo {Show 14 fields
pub currency: Option<String>,
pub total_asset: Option<String>,
pub hold: Option<String>,
pub available: Option<String>,
pub drawable: Option<String>,
pub mv: Option<String>,
pub long_mv: Option<String>,
pub short_mv: Option<String>,
pub unrealized_profit: Option<String>,
pub realized_profit: Option<String>,
pub average_profit: Option<String>,
pub diluted_profit: Option<String>,
pub max_power_long: Option<String>,
pub max_power_short: Option<String>,
}Expand description
账户资金信息
Fields§
§currency: Option<String>标准货币代码,参考ISO_4217,目前支持币种如HKD, USD,CNH,SGD,JPY
total_asset: Option<String>资产净值
hold: Option<String>冻结资金
available: Option<String>可用资金
drawable: Option<String>最大可提金额
mv: Option<String>持仓市值
long_mv: Option<String>多头持仓市值
short_mv: Option<String>空头持仓市值
unrealized_profit: Option<String>未实现盈亏
realized_profit: Option<String>已实现盈亏
average_profit: Option<String>累计持仓盈亏(股票)/收益(基金)
diluted_profit: Option<String>累计持仓盈亏(股票)/收益(基金)
max_power_long: Option<String>max_power_long/max_power_short 这两个字段是临时方案,为了快速实现客户端区分是否需要刷新可买可卖数量的需求, 【其他场景不要使用】 这里的概念有歧义,是历史包袱,还没有时间整体梳理优化
最大最多购买力,max_power_long=available
max_power_short: Option<String>最大做空购买力,max_power_short=0
Implementations§
Source§impl AccFundInfo
impl AccFundInfo
Sourcepub fn currency(&self) -> &str
pub fn currency(&self) -> &str
Returns the value of currency, or the default value if currency is unset.
Sourcepub fn total_asset(&self) -> &str
pub fn total_asset(&self) -> &str
Returns the value of total_asset, or the default value if total_asset is unset.
Sourcepub fn available(&self) -> &str
pub fn available(&self) -> &str
Returns the value of available, or the default value if available is unset.
Sourcepub fn drawable(&self) -> &str
pub fn drawable(&self) -> &str
Returns the value of drawable, or the default value if drawable is unset.
Sourcepub fn long_mv(&self) -> &str
pub fn long_mv(&self) -> &str
Returns the value of long_mv, or the default value if long_mv is unset.
Sourcepub fn short_mv(&self) -> &str
pub fn short_mv(&self) -> &str
Returns the value of short_mv, or the default value if short_mv is unset.
Sourcepub fn unrealized_profit(&self) -> &str
pub fn unrealized_profit(&self) -> &str
Returns the value of unrealized_profit, or the default value if unrealized_profit is unset.
Sourcepub fn realized_profit(&self) -> &str
pub fn realized_profit(&self) -> &str
Returns the value of realized_profit, or the default value if realized_profit is unset.
Sourcepub fn average_profit(&self) -> &str
pub fn average_profit(&self) -> &str
Returns the value of average_profit, or the default value if average_profit is unset.
Sourcepub fn diluted_profit(&self) -> &str
pub fn diluted_profit(&self) -> &str
Returns the value of diluted_profit, or the default value if diluted_profit is unset.
Sourcepub fn max_power_long(&self) -> &str
pub fn max_power_long(&self) -> &str
Returns the value of max_power_long, or the default value if max_power_long is unset.
Sourcepub fn max_power_short(&self) -> &str
pub fn max_power_short(&self) -> &str
Returns the value of max_power_short, or the default value if max_power_short is unset.
Trait Implementations§
Source§impl Clone for AccFundInfo
impl Clone for AccFundInfo
Source§fn clone(&self) -> AccFundInfo
fn clone(&self) -> AccFundInfo
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for AccFundInfo
impl Debug for AccFundInfo
Source§impl Default for AccFundInfo
impl Default for AccFundInfo
Source§impl Hash for AccFundInfo
impl Hash for AccFundInfo
Source§impl Message for AccFundInfo
impl Message for AccFundInfo
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 AccFundInfo
impl PartialEq for AccFundInfo
impl Eq for AccFundInfo
impl StructuralPartialEq for AccFundInfo
Auto Trait Implementations§
impl Freeze for AccFundInfo
impl RefUnwindSafe for AccFundInfo
impl Send for AccFundInfo
impl Sync for AccFundInfo
impl Unpin for AccFundInfo
impl UnsafeUnpin for AccFundInfo
impl UnwindSafe for AccFundInfo
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.