pub struct SnapshotBasicData {Show 42 fields
pub security: Security,
pub name: Option<String>,
pub type: i32,
pub is_suspend: bool,
pub list_time: String,
pub lot_size: i32,
pub price_spread: f64,
pub update_time: String,
pub high_price: f64,
pub open_price: f64,
pub low_price: f64,
pub last_close_price: f64,
pub cur_price: f64,
pub volume: i64,
pub turnover: f64,
pub turnover_rate: f64,
pub list_timestamp: Option<f64>,
pub update_timestamp: Option<f64>,
pub ask_price: Option<f64>,
pub bid_price: Option<f64>,
pub ask_vol: Option<i64>,
pub bid_vol: Option<i64>,
pub enable_margin: Option<bool>,
pub mortgage_ratio: Option<f64>,
pub long_margin_initial_ratio: Option<f64>,
pub enable_short_sell: Option<bool>,
pub short_sell_rate: Option<f64>,
pub short_available_volume: Option<i64>,
pub short_margin_initial_ratio: Option<f64>,
pub amplitude: Option<f64>,
pub avg_price: Option<f64>,
pub bid_ask_ratio: Option<f64>,
pub volume_ratio: Option<f64>,
pub highest52_weeks_price: Option<f64>,
pub lowest52_weeks_price: Option<f64>,
pub highest_history_price: Option<f64>,
pub lowest_history_price: Option<f64>,
pub pre_market: Option<PreAfterMarketData>,
pub after_market: Option<PreAfterMarketData>,
pub sec_status: Option<i32>,
pub close_price5_minute: Option<f64>,
pub overnight: Option<PreAfterMarketData>,
}Expand description
基本快照数据
Fields§
§security: Security股票
name: Option<String>股票名称
type: i32Qot_Common.SecurityType,股票类型
is_suspend: bool是否停牌
list_time: String上市时间字符串
lot_size: i32每手数量
price_spread: f64价差
update_time: String更新时间字符串
high_price: f64最高价
open_price: f64开盘价
low_price: f64最低价
last_close_price: f64昨收价
cur_price: f64最新价
volume: i64成交量
turnover: f64成交额
turnover_rate: f64换手率(该字段为百分比字段,默认不展示%,如20实际对应20%)
list_timestamp: Option<f64>上市时间戳
update_timestamp: Option<f64>更新时间戳
ask_price: Option<f64>卖价
bid_price: Option<f64>买价
ask_vol: Option<i64>卖量
bid_vol: Option<i64>买量
enable_margin: Option<bool>是否可融资,如果为true,后两个字段才有意义
mortgage_ratio: Option<f64>股票抵押率(该字段为百分比字段,默认不展示%,如20实际对应20%)
long_margin_initial_ratio: Option<f64>融资初始保证金率(该字段为百分比字段,默认不展示%,如20实际对应20%)
enable_short_sell: Option<bool>是否可卖空,如果为true,后三个字段才有意义
short_sell_rate: Option<f64>卖空参考利率(该字段为百分比字段,默认不展示%,如20实际对应20%)
short_available_volume: Option<i64>剩余可卖空数量(股)
short_margin_initial_ratio: Option<f64>卖空(融券)初始保证金率(该字段为百分比字段,默认不展示%,如20实际对应20%)
amplitude: Option<f64>振幅(该字段为百分比字段,默认不展示%,如20实际对应20%)
avg_price: Option<f64>平均价
bid_ask_ratio: Option<f64>委比(该字段为百分比字段,默认不展示%,如20实际对应20%)
volume_ratio: Option<f64>量比
highest52_weeks_price: Option<f64>52周最高价
lowest52_weeks_price: Option<f64>52周最低价
highest_history_price: Option<f64>历史最高价
lowest_history_price: Option<f64>历史最低价
pre_market: Option<PreAfterMarketData>Qot_Common::PreAfterMarketData 盘前数据
after_market: Option<PreAfterMarketData>Qot_Common::PreAfterMarketData 盘后数据
sec_status: Option<i32>Qot_Common::SecurityStatus 股票状态
close_price5_minute: Option<f64>5分钟收盘价
overnight: Option<PreAfterMarketData>Qot_Common::PreAfterMarketData 夜盘数据
Implementations§
Source§impl SnapshotBasicData
impl SnapshotBasicData
Sourcepub fn list_timestamp(&self) -> f64
pub fn list_timestamp(&self) -> f64
Returns the value of list_timestamp, or the default value if list_timestamp is unset.
Sourcepub fn update_timestamp(&self) -> f64
pub fn update_timestamp(&self) -> f64
Returns the value of update_timestamp, or the default value if update_timestamp is unset.
Sourcepub fn ask_price(&self) -> f64
pub fn ask_price(&self) -> f64
Returns the value of ask_price, or the default value if ask_price is unset.
Sourcepub fn bid_price(&self) -> f64
pub fn bid_price(&self) -> f64
Returns the value of bid_price, or the default value if bid_price is unset.
Sourcepub fn ask_vol(&self) -> i64
pub fn ask_vol(&self) -> i64
Returns the value of ask_vol, or the default value if ask_vol is unset.
Sourcepub fn bid_vol(&self) -> i64
pub fn bid_vol(&self) -> i64
Returns the value of bid_vol, or the default value if bid_vol is unset.
Sourcepub fn enable_margin(&self) -> bool
pub fn enable_margin(&self) -> bool
Returns the value of enable_margin, or the default value if enable_margin is unset.
Sourcepub fn mortgage_ratio(&self) -> f64
pub fn mortgage_ratio(&self) -> f64
Returns the value of mortgage_ratio, or the default value if mortgage_ratio is unset.
Sourcepub fn long_margin_initial_ratio(&self) -> f64
pub fn long_margin_initial_ratio(&self) -> f64
Returns the value of long_margin_initial_ratio, or the default value if long_margin_initial_ratio is unset.
Sourcepub fn enable_short_sell(&self) -> bool
pub fn enable_short_sell(&self) -> bool
Returns the value of enable_short_sell, or the default value if enable_short_sell is unset.
Sourcepub fn short_sell_rate(&self) -> f64
pub fn short_sell_rate(&self) -> f64
Returns the value of short_sell_rate, or the default value if short_sell_rate is unset.
Sourcepub fn short_available_volume(&self) -> i64
pub fn short_available_volume(&self) -> i64
Returns the value of short_available_volume, or the default value if short_available_volume is unset.
Sourcepub fn short_margin_initial_ratio(&self) -> f64
pub fn short_margin_initial_ratio(&self) -> f64
Returns the value of short_margin_initial_ratio, or the default value if short_margin_initial_ratio is unset.
Sourcepub fn amplitude(&self) -> f64
pub fn amplitude(&self) -> f64
Returns the value of amplitude, or the default value if amplitude is unset.
Sourcepub fn avg_price(&self) -> f64
pub fn avg_price(&self) -> f64
Returns the value of avg_price, or the default value if avg_price is unset.
Sourcepub fn bid_ask_ratio(&self) -> f64
pub fn bid_ask_ratio(&self) -> f64
Returns the value of bid_ask_ratio, or the default value if bid_ask_ratio is unset.
Sourcepub fn volume_ratio(&self) -> f64
pub fn volume_ratio(&self) -> f64
Returns the value of volume_ratio, or the default value if volume_ratio is unset.
Sourcepub fn highest52_weeks_price(&self) -> f64
pub fn highest52_weeks_price(&self) -> f64
Returns the value of highest52_weeks_price, or the default value if highest52_weeks_price is unset.
Sourcepub fn lowest52_weeks_price(&self) -> f64
pub fn lowest52_weeks_price(&self) -> f64
Returns the value of lowest52_weeks_price, or the default value if lowest52_weeks_price is unset.
Sourcepub fn highest_history_price(&self) -> f64
pub fn highest_history_price(&self) -> f64
Returns the value of highest_history_price, or the default value if highest_history_price is unset.
Sourcepub fn lowest_history_price(&self) -> f64
pub fn lowest_history_price(&self) -> f64
Returns the value of lowest_history_price, or the default value if lowest_history_price is unset.
Sourcepub fn sec_status(&self) -> i32
pub fn sec_status(&self) -> i32
Returns the value of sec_status, or the default value if sec_status is unset.
Sourcepub fn close_price5_minute(&self) -> f64
pub fn close_price5_minute(&self) -> f64
Returns the value of close_price5_minute, or the default value if close_price5_minute is unset.
Trait Implementations§
Source§impl Clone for SnapshotBasicData
impl Clone for SnapshotBasicData
Source§fn clone(&self) -> SnapshotBasicData
fn clone(&self) -> SnapshotBasicData
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for SnapshotBasicData
impl Debug for SnapshotBasicData
Source§impl Default for SnapshotBasicData
impl Default for SnapshotBasicData
Source§impl<'de> Deserialize<'de> for SnapshotBasicDatawhere
SnapshotBasicData: Default,
impl<'de> Deserialize<'de> for SnapshotBasicDatawhere
SnapshotBasicData: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Message for SnapshotBasicData
impl Message for SnapshotBasicData
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.