Skip to main content

SecurityStaticInfo

Struct SecurityStaticInfo 

Source
pub struct SecurityStaticInfo {
    pub security: Security,
    pub id: i64,
    pub lot_size: i32,
    pub sec_type: i32,
    pub name: String,
    pub list_time: String,
    pub delisting: bool,
    pub exch_type: i32,
}
Expand description

股票静态信息

Fields§

§security: Security§id: i64§lot_size: i32§sec_type: i32§name: String§list_time: String§delisting: bool§exch_type: i32

v1.4.93 P1-3 (BUG-5318-003): 透传 proto SecurityStaticBasic.exchType (field 9). daemon 端 make_static_info 已用 derive_exch_type_with_fallback 把 cache miss / 历史 SQLite 行的 exch_type=0 通过 mkt_id 派生(含 US 期货 60-109 range NYMEX/COMEX/ CBOT/CME/CBOE). 这里只做透传; user-facing exchange_code 字符串 通过 Self::exchange_code() 派生.

Implementations§

Source§

impl SecurityStaticInfo

Source

pub fn from_proto(info: &SecurityStaticInfo) -> Self

Source

pub fn exchange_code(&self) -> Option<&'static str>

v1.4.93 P1-3 (BUG-5318-003): 派生 user-facing exchange code 字符串 (e.g. “CME”/“NYMEX”/“CBOT”/“CBOE”/“COMEX” for US 期货, “NYSE”/“Nasdaq” for US 股, “HK_MainBoard”/“SH”/“SZ” 等). 见 futu_core::exch_type::exch_type_to_string 完整映射表.

返回 None 表示 Unknown(0) 或 ExchType 表外值, caller 一般 .map(String::from) 推送到 JSON / display.

Trait Implementations§

Source§

impl Clone for SecurityStaticInfo

Source§

fn clone(&self) -> SecurityStaticInfo

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 SecurityStaticInfo

Source§

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

Formats the value using the given formatter. Read more

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

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