Skip to main content

CsStockItem

Struct CsStockItem 

Source
pub struct CsStockItem {
Show 59 fields pub stock_id: u64, pub sequence: u64, pub code: String, pub instrument_type: Option<u32>, pub sub_instrument_type: Option<u32>, pub tc_name: Option<String>, pub sc_name: Option<String>, pub pinyin: Option<String>, pub short_pinyin: Option<String>, pub eng_name: Option<String>, pub key_words: Option<String>, pub currency_code: Option<u32>, pub lot_size: Option<u32>, pub spread_table_code: Option<u32>, pub listing_date: Option<u32>, pub market_code: Option<u32>, pub warrnt_stock_owner: Option<u64>, pub warrnt_type: Option<u32>, pub arr_plate_id: Vec<u64>, pub delete_flag: Option<u32>, pub linkage_stock_id: Option<u64>, pub plate_type: Option<u32>, pub tradetime_table_code: Option<u32>, pub delisting_flag: Option<u32>, pub no_search: Option<u32>, pub no_subscription: Option<u32>, pub cas_flag: Option<u32>, pub vcm_flag: Option<u32>, pub margin_flag: Option<u32>, pub sell_short_flag: Option<u32>, pub underlying_stock_id: Option<u64>, pub adr_linkage_stock_id: Option<u64>, pub cdr_linkage_stock_id: Option<u64>, pub time_zone: Option<String>, pub price_accuracy: Option<i32>, pub linkage_future_id: Option<u64>, pub future_last_trade_time: Option<u32>, pub dark_trade_ts: Option<u32>, pub reverse_forex_id: Option<u64>, pub zhuli_id: Option<u64>, pub origin_id: Option<u64>, pub quote_display_type: Option<u32>, pub sc_name_abbr: Option<String>, pub tc_name_abbr: Option<String>, pub eng_name_abbr: Option<String>, pub hp_contract_size: Option<i64>, pub hp_multiplier: Option<i64>, pub cdr_profit_making_flag: Option<i32>, pub cdr_diff_rights_flag: Option<i32>, pub vie_flag: Option<i32>, pub registration_flag: Option<i32>, pub industry_id: Option<u64>, pub cc_origin: Option<String>, pub cc_destination: Option<String>, pub ipo_timestamp: Option<i64>, pub instrument_type_v2: Option<u32>, pub sub_instrument_type_v2: Option<u32>, pub exchange: Option<String>, pub listed_exchange: Option<String>,
}

Fields§

§stock_id: u64

股票ID

§sequence: u64

股票版本号

§code: String

原始代码

§instrument_type: Option<u32>

股票类型

§sub_instrument_type: Option<u32>

子类型,参考SubInstrumentType

§tc_name: Option<String>

繁体中文名称

§sc_name: Option<String>

简体中文名称

§pinyin: Option<String>

拼音

§short_pinyin: Option<String>

拼音简称

§eng_name: Option<String>

英文名

§key_words: Option<String>

关键词

§currency_code: Option<u32>

货币类型

§lot_size: Option<u32>

每手数量

§spread_table_code: Option<u32>

价位表编码

§listing_date: Option<u32>

上市日期

§market_code: Option<u32>

市场编码

§warrnt_stock_owner: Option<u64>

窝轮所属正股ID

§warrnt_type: Option<u32>

窝轮类型

§arr_plate_id: Vec<u64>

股票所属板块ID列表。该字段作废,所属板块从板块服务单独拉取-20170308

§delete_flag: Option<u32>

删除标记,非0表示股票已删除

§linkage_stock_id: Option<u64>

对于港股和A股的正股,表示关联市场的股票ID

§plate_type: Option<u32>

板块类型(0:默认,1:有走势数据等)

§tradetime_table_code: Option<u32>

交易时间表ID

§delisting_flag: Option<u32>

退市标记,非0表示退市. 退市的股票也参与check_sum的计算

§no_search: Option<u32>

不被搜索标记, 非0表示不可搜索

§no_subscription: Option<u32>

不可订阅/不可自选/不显示图表等标记, 非0表示不可添加自选, 不可订阅, 不显示图表

§cas_flag: Option<u32>

是否支持CAS. 1表示支持CAS, 0或者没有返回该字段, 表示不支持CAS

§vcm_flag: Option<u32>

是否支持VCM. 1表示支持VCM, 0或者没有返回该字段, 表示不支持VCM

§margin_flag: Option<u32>

融资标记. 对于港股, 该字段表示融资抵押率, 放大100000倍, 例如抵押率65%, 则返回65000. 0或者没有返回该字段, 表示不支持融资

§sell_short_flag: Option<u32>

对于美股, 该字段表示是否支持融资, 0或者没有返回该字段, 表示不支持融资, 其它表示支持融资 对于A股, 该字段表示融资抵押率, 放大100000倍, 例如抵押率65%, 则返回65000. 0或者没有返回该字段, 表示不支持融资

是否支持卖空. 1表示支持卖空; 0或者没有返回该字段, 表示不支持卖空

§underlying_stock_id: Option<u64>

对于指数期货,该字段表示其标的指数ID; 对于美股期货,该字段表示其标的股票ID

§adr_linkage_stock_id: Option<u64>

ADR关联股票ID,非0时有效。对港股返回对应的ADR股票ID,对ADR返回对应的港股股票ID

§cdr_linkage_stock_id: Option<u64>

CDR关联股票ID,非0时有效。对美股或者港股,返回其对应的CDR股票ID;对CDR返回对应的港股或美股股票ID

§time_zone: Option<String>

时区, 例如“America/New_York“, “America/Chicaco”. 注意:目前只有美股期货会返回该字段,其它股票不会返回该字段

§price_accuracy: Option<i32>

价格字段向用户显示小数点后的位数

§linkage_future_id: Option<u64>

相关期货ID

§future_last_trade_time: Option<u32>

期货最后交易日。只有普通期货合约才会返回该字段;主连合约、非期货类型不会返回该字段

§dark_trade_ts: Option<u32>

暗盘交易时间,北京时间当天0点

§reverse_forex_id: Option<u64>

反向外汇ID

§zhuli_id: Option<u64>§origin_id: Option<u64>

当月、下月、主力实际期货stock_id,普通为0

§quote_display_type: Option<u32>

报价显示类型,0: 十进制小数点,1:32进制点数报价

§sc_name_abbr: Option<String>

简体中文名称-简称

§tc_name_abbr: Option<String>

繁体中文名称-简称

§eng_name_abbr: Option<String>

英文名称-简称

§hp_contract_size: Option<i64>

期货合约规模,放大10的9次方

§hp_multiplier: Option<i64>

期货高精度合约乘数,放大10的9次方

§cdr_profit_making_flag: Option<i32>

是否上市时尚未盈利

§cdr_diff_rights_flag: Option<i32>

是否同股同权

§vie_flag: Option<i32>

是否具有协议控制架构

§registration_flag: Option<i32>

是否注册制下发行上市

§industry_id: Option<u64>

所属行业

§cc_origin: Option<String>

货币对-第一个货币(左侧货币)

§cc_destination: Option<String>

货币对-第二个货币(右侧货币)

§ipo_timestamp: Option<i64>

上市时间(上市地当地时间0点对应时间戳)

§instrument_type_v2: Option<u32>

新行情分类,参考fservice公共协议security_type.proto 的InstrumentTypeV2枚举

§sub_instrument_type_v2: Option<u32>

新行情分类子类,参考fservice公共协议security_type.proto 的SubInstrumentTypeV2枚举

§exchange: Option<String>

v1.4.110 final E.5 P2#6: 补 field 57+74 对齐 C++ Quote/stock_list_sync.proto:215,221 exchange: 交易所 (字符串, e.g. “SEHK”, “NASDAQ”, “NYSE”, “SSE”, “SZSE”, “HKEX”) listed_exchange: 股票上市交易所 (字符串, 可能跟 exchange 不同, e.g. dual-listed ADR) 用途: 推荐 cache.exchange (数据驱动) > pattern fallback. Pitfall #35 (C++ 数据驱动 vs Rust 启发式).

交易所

§listed_exchange: Option<String>

股票上市交易所

Implementations§

Source§

impl CsStockItem

Source

pub fn instrument_type(&self) -> u32

Returns the value of instrument_type, or the default value if instrument_type is unset.

Source

pub fn tc_name(&self) -> &str

Returns the value of tc_name, or the default value if tc_name is unset.

Source

pub fn sc_name(&self) -> &str

Returns the value of sc_name, or the default value if sc_name is unset.

Source

pub fn pinyin(&self) -> &str

Returns the value of pinyin, or the default value if pinyin is unset.

Source

pub fn short_pinyin(&self) -> &str

Returns the value of short_pinyin, or the default value if short_pinyin is unset.

Source

pub fn eng_name(&self) -> &str

Returns the value of eng_name, or the default value if eng_name is unset.

Source

pub fn key_words(&self) -> &str

Returns the value of key_words, or the default value if key_words is unset.

Source

pub fn currency_code(&self) -> u32

Returns the value of currency_code, or the default value if currency_code is unset.

Source

pub fn lot_size(&self) -> u32

Returns the value of lot_size, or the default value if lot_size is unset.

Source

pub fn spread_table_code(&self) -> u32

Returns the value of spread_table_code, or the default value if spread_table_code is unset.

Source

pub fn listing_date(&self) -> u32

Returns the value of listing_date, or the default value if listing_date is unset.

Source

pub fn market_code(&self) -> u32

Returns the value of market_code, or the default value if market_code is unset.

Source

pub fn warrnt_stock_owner(&self) -> u64

Returns the value of warrnt_stock_owner, or the default value if warrnt_stock_owner is unset.

Source

pub fn warrnt_type(&self) -> u32

Returns the value of warrnt_type, or the default value if warrnt_type is unset.

Source

pub fn delete_flag(&self) -> u32

Returns the value of delete_flag, or the default value if delete_flag is unset.

Source

pub fn linkage_stock_id(&self) -> u64

Returns the value of linkage_stock_id, or the default value if linkage_stock_id is unset.

Source

pub fn plate_type(&self) -> u32

Returns the value of plate_type, or the default value if plate_type is unset.

Source

pub fn tradetime_table_code(&self) -> u32

Returns the value of tradetime_table_code, or the default value if tradetime_table_code is unset.

Source

pub fn delisting_flag(&self) -> u32

Returns the value of delisting_flag, or the default value if delisting_flag is unset.

Returns the value of no_search, or the default value if no_search is unset.

Source

pub fn no_subscription(&self) -> u32

Returns the value of no_subscription, or the default value if no_subscription is unset.

Source

pub fn cas_flag(&self) -> u32

Returns the value of cas_flag, or the default value if cas_flag is unset.

Source

pub fn vcm_flag(&self) -> u32

Returns the value of vcm_flag, or the default value if vcm_flag is unset.

Source

pub fn margin_flag(&self) -> u32

Returns the value of margin_flag, or the default value if margin_flag is unset.

Source

pub fn sell_short_flag(&self) -> u32

Returns the value of sell_short_flag, or the default value if sell_short_flag is unset.

Source

pub fn sub_instrument_type(&self) -> u32

Returns the value of sub_instrument_type, or the default value if sub_instrument_type is unset.

Source

pub fn underlying_stock_id(&self) -> u64

Returns the value of underlying_stock_id, or the default value if underlying_stock_id is unset.

Source

pub fn adr_linkage_stock_id(&self) -> u64

Returns the value of adr_linkage_stock_id, or the default value if adr_linkage_stock_id is unset.

Source

pub fn cdr_linkage_stock_id(&self) -> u64

Returns the value of cdr_linkage_stock_id, or the default value if cdr_linkage_stock_id is unset.

Source

pub fn time_zone(&self) -> &str

Returns the value of time_zone, or the default value if time_zone is unset.

Source

pub fn price_accuracy(&self) -> i32

Returns the value of price_accuracy, or the default value if price_accuracy is unset.

Source

pub fn linkage_future_id(&self) -> u64

Returns the value of linkage_future_id, or the default value if linkage_future_id is unset.

Source

pub fn future_last_trade_time(&self) -> u32

Returns the value of future_last_trade_time, or the default value if future_last_trade_time is unset.

Source

pub fn dark_trade_ts(&self) -> u32

Returns the value of dark_trade_ts, or the default value if dark_trade_ts is unset.

Source

pub fn reverse_forex_id(&self) -> u64

Returns the value of reverse_forex_id, or the default value if reverse_forex_id is unset.

Source

pub fn zhuli_id(&self) -> u64

Returns the value of zhuli_id, or the default value if zhuli_id is unset.

Source

pub fn origin_id(&self) -> u64

Returns the value of origin_id, or the default value if origin_id is unset.

Source

pub fn quote_display_type(&self) -> u32

Returns the value of quote_display_type, or the default value if quote_display_type is unset.

Source

pub fn sc_name_abbr(&self) -> &str

Returns the value of sc_name_abbr, or the default value if sc_name_abbr is unset.

Source

pub fn tc_name_abbr(&self) -> &str

Returns the value of tc_name_abbr, or the default value if tc_name_abbr is unset.

Source

pub fn eng_name_abbr(&self) -> &str

Returns the value of eng_name_abbr, or the default value if eng_name_abbr is unset.

Source

pub fn hp_contract_size(&self) -> i64

Returns the value of hp_contract_size, or the default value if hp_contract_size is unset.

Source

pub fn hp_multiplier(&self) -> i64

Returns the value of hp_multiplier, or the default value if hp_multiplier is unset.

Source

pub fn cdr_profit_making_flag(&self) -> i32

Returns the value of cdr_profit_making_flag, or the default value if cdr_profit_making_flag is unset.

Source

pub fn cdr_diff_rights_flag(&self) -> i32

Returns the value of cdr_diff_rights_flag, or the default value if cdr_diff_rights_flag is unset.

Source

pub fn vie_flag(&self) -> i32

Returns the value of vie_flag, or the default value if vie_flag is unset.

Source

pub fn registration_flag(&self) -> i32

Returns the value of registration_flag, or the default value if registration_flag is unset.

Source

pub fn industry_id(&self) -> u64

Returns the value of industry_id, or the default value if industry_id is unset.

Source

pub fn exchange(&self) -> &str

Returns the value of exchange, or the default value if exchange is unset.

Source

pub fn cc_origin(&self) -> &str

Returns the value of cc_origin, or the default value if cc_origin is unset.

Source

pub fn cc_destination(&self) -> &str

Returns the value of cc_destination, or the default value if cc_destination is unset.

Source

pub fn ipo_timestamp(&self) -> i64

Returns the value of ipo_timestamp, or the default value if ipo_timestamp is unset.

Source

pub fn instrument_type_v2(&self) -> u32

Returns the value of instrument_type_v2, or the default value if instrument_type_v2 is unset.

Source

pub fn sub_instrument_type_v2(&self) -> u32

Returns the value of sub_instrument_type_v2, or the default value if sub_instrument_type_v2 is unset.

Source

pub fn listed_exchange(&self) -> &str

Returns the value of listed_exchange, or the default value if listed_exchange is unset.

Trait Implementations§

Source§

impl Clone for CsStockItem

Source§

fn clone(&self) -> CsStockItem

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for CsStockItem

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for CsStockItem

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl Hash for CsStockItem

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl Message for CsStockItem

Source§

fn encoded_len(&self) -> usize

Returns the encoded length of the message without a length delimiter.
Source§

fn clear(&mut self)

Clears the message, resetting all fields to their default.
Source§

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,

Encodes the message to a newly allocated buffer.
Source§

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,

Encodes the message with a length-delimiter to a newly allocated buffer.
Source§

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,

Decodes a length-delimited instance of the message from the buffer.
Source§

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 more
Source§

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.
Source§

impl PartialEq for CsStockItem

Source§

fn eq(&self, other: &CsStockItem) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Eq for CsStockItem

Source§

impl StructuralPartialEq for CsStockItem

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> PolicyExt for T
where T: ?Sized,

§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns [Action::Follow] only if self and other return Action::Follow. Read more
§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns [Action::Follow] if either self or other returns Action::Follow. Read more
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more