pub struct AccPstnInfoV2 {
pub pstn_id: Option<String>,
pub pstn_type: Option<i32>,
pub account_market: Option<u32>,
pub symbol: Option<String>,
pub exchange: Option<String>,
pub qty: Option<String>,
pub qty_hold: Option<String>,
pub qty_avbl: Option<String>,
pub stock_name: Option<String>,
pub stock_id: Option<String>,
pub stock_market: Option<u32>,
pub currency_data_list: Vec<CurrencyData>,
}Expand description
账户持仓信息
Fields§
§pstn_id: Option<String>币种无关字段
server保证唯一
pstn_type: Option<i32>0->多仓, 1->空仓
account_market: Option<u32>账号对应的市场, 取值参考odr_sys_cmn.AccountMarket
symbol: Option<String>持仓代码,如BTC、ETH
exchange: Option<String>交易所,该字段对于crypto没有意义,客户端有依赖,所以保留,固定返回CRYPTO
qty: Option<String>空仓为负数,若数量为0,则显示 –
qty_hold: Option<String>冻结数量
qty_avbl: Option<String>可用数量
stock_name: Option<String>币种名称
stock_id: Option<String>持仓行情ID
stock_market: Option<u32>持仓对应的市场, 取值参考odr_sys_cmn.StockMarket
currency_data_list: Vec<CurrencyData>分币种的持仓金额信息
Implementations§
Source§impl AccPstnInfoV2
impl AccPstnInfoV2
Sourcepub fn pstn_id(&self) -> &str
pub fn pstn_id(&self) -> &str
Returns the value of pstn_id, or the default value if pstn_id is unset.
Sourcepub fn pstn_type(&self) -> i32
pub fn pstn_type(&self) -> i32
Returns the value of pstn_type, or the default value if pstn_type is unset.
Sourcepub fn account_market(&self) -> u32
pub fn account_market(&self) -> u32
Returns the value of account_market, or the default value if account_market is unset.
Sourcepub fn symbol(&self) -> &str
pub fn symbol(&self) -> &str
Returns the value of symbol, or the default value if 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 qty_hold(&self) -> &str
pub fn qty_hold(&self) -> &str
Returns the value of qty_hold, or the default value if qty_hold is unset.
Sourcepub fn qty_avbl(&self) -> &str
pub fn qty_avbl(&self) -> &str
Returns the value of qty_avbl, or the default value if qty_avbl is unset.
Sourcepub fn stock_name(&self) -> &str
pub fn stock_name(&self) -> &str
Returns the value of stock_name, or the default value if stock_name is unset.
Sourcepub fn stock_id(&self) -> &str
pub fn stock_id(&self) -> &str
Returns the value of stock_id, or the default value if stock_id is unset.
Sourcepub fn stock_market(&self) -> u32
pub fn stock_market(&self) -> u32
Returns the value of stock_market, or the default value if stock_market is unset.
Trait Implementations§
Source§impl Clone for AccPstnInfoV2
impl Clone for AccPstnInfoV2
Source§fn clone(&self) -> AccPstnInfoV2
fn clone(&self) -> AccPstnInfoV2
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for AccPstnInfoV2
impl Debug for AccPstnInfoV2
Source§impl Default for AccPstnInfoV2
impl Default for AccPstnInfoV2
Source§impl Message for AccPstnInfoV2
impl Message for AccPstnInfoV2
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.