pub struct TimeShareSection {
pub trade_section: Option<u32>,
pub last_close_price: Option<i64>,
pub point_list: Vec<TimeSharePoint>,
pub time_zone: Option<i32>,
pub security_id: Option<u64>,
}Expand description
分时数据-一个交易时段 每个section里的分时点涨跌幅应该用本section里last_close_price计算 每个section里的分时点时间应该用本section里的time_zone来计算
Fields§
§trade_section: Option<u32>交易阶段类型,见TradeSection枚举
last_close_price: Option<i64>昨收价(参考对比价),单位: *10^9
point_list: Vec<TimeSharePoint>数据点列表,一分钟一个点
time_zone: Option<i32>时间时区,用于显示当地时间计算
security_id: Option<u64>股票ID
Implementations§
Sourcepub fn trade_section(&self) -> u32
pub fn trade_section(&self) -> u32
Returns the value of trade_section, or the default value if trade_section is unset.
Sourcepub fn last_close_price(&self) -> i64
pub fn last_close_price(&self) -> i64
Returns the value of last_close_price, or the default value if last_close_price is unset.
Sourcepub fn time_zone(&self) -> i32
pub fn time_zone(&self) -> i32
Returns the value of time_zone, or the default value if time_zone is unset.
Sourcepub fn security_id(&self) -> u64
pub fn security_id(&self) -> u64
Returns the value of security_id, or the default value if security_id is unset.
Trait Implementations§
Source§fn clone(&self) -> TimeShareSection
fn clone(&self) -> TimeShareSection
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
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,
Encodes the message to a buffer. Read more
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message to a newly allocated buffer.
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,
Encodes the message with a length-delimiter to a buffer. Read more
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,
Encodes the message with a length-delimiter to a newly allocated buffer.
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes an instance of the message from a buffer. Read more
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,
Decodes a length-delimited instance of the message from the buffer.
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,
Decodes an instance of the message from a buffer, and merges it into
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,
Decodes a length-delimited instance of the message from buffer, and
merges it into
self.Auto Trait Implementations§
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
Mutably borrows from an owned value. Read more