pub struct TickerFullPoint {Show 46 fields
pub ts_ms: i64,
pub last: f64,
pub bid: f64,
pub ask: f64,
pub bid_qty: f64,
pub ask_qty: f64,
pub high_24h: f64,
pub low_24h: f64,
pub vol_24h: f64,
pub quote_vol_24h: f64,
pub price_change_24h: f64,
pub price_change_pct_24h: f64,
pub open_price: f64,
pub prev_close_price: f64,
pub prev_price_24h: f64,
pub prev_price_1h: f64,
pub weighted_avg_price: f64,
pub open_utc: f64,
pub turnover_24h: f64,
pub first_id: Option<i64>,
pub last_id: Option<i64>,
pub count: Option<i64>,
pub mark_price: f64,
pub index_price: f64,
pub open_interest: f64,
pub open_interest_value: f64,
pub single_open_interest: f64,
pub funding_rate: f64,
pub next_funding_time: Option<i64>,
pub funding_interval_hour: f64,
pub funding_cap: f64,
pub basis: f64,
pub basis_rate: f64,
pub predicted_delivery_price: f64,
pub delivery_time: Option<i64>,
pub settlement_price: f64,
pub funding_8h: f64,
pub min_price: f64,
pub max_price: f64,
pub volume_notional: f64,
pub last_qty: f64,
pub interest_value: f64,
pub last_trade_time: Option<i64>,
pub open_time: Option<i64>,
pub update_id: Option<i64>,
pub state: Option<String>,
}Expand description
Full Ticker record — every numeric wire field.
Layout (all LE): u64 ts_ms (8) f64 last (8) f64 bid, ask, bid_qty, ask_qty (4 × 8 = 32) f64 high_24h, low_24h, vol_24h, quote_vol_24h (4 × 8 = 32) f64 price_change_24h, price_change_pct_24h (2 × 8 = 16) f64 open_price, prev_close_price (2 × 8 = 16) f64 prev_price_24h, prev_price_1h (2 × 8 = 16) f64 weighted_avg_price, open_utc, turnover_24h (3 × 8 = 24) u64 first_id, last_id, count (sentinels) (3 × 8 = 24) f64 mark_price, index_price (2 × 8 = 16) f64 open_interest, open_interest_value (2 × 8 = 16) f64 single_open_interest (8) f64 funding_rate (8) u64 next_funding_time (sentinel) (8) f64 funding_interval_hour, funding_cap (2 × 8 = 16) f64 basis, basis_rate (2 × 8 = 16) f64 predicted_delivery_price (8) u64 delivery_time (sentinel) (8) f64 settlement_price, funding_8h (2 × 8 = 16) f64 min_price, max_price, volume_notional (3 × 8 = 24) f64 last_qty, interest_value (2 × 8 = 16) u64 last_trade_time, open_time, update_id (senti) (3 × 8 = 24) u64 blob_offset (8), u32 blob_len (4) (12)
Fixed total: 8+8+32+32+16+16+16+24+24+16+16+8+8+8+16+16+8+8+16+24+16+24+12 = 376 B
Blob (variable): u16-len-prefixed UTF-8 state string (empty if None).
update_id is stored as u64 with sentinel.
Fields§
§ts_ms: i64§last: f64§bid: f64§ask: f64§bid_qty: f64§ask_qty: f64§high_24h: f64§low_24h: f64§vol_24h: f64§quote_vol_24h: f64§price_change_24h: f64§price_change_pct_24h: f64§open_price: f64§prev_close_price: f64§prev_price_24h: f64§prev_price_1h: f64§weighted_avg_price: f64§open_utc: f64§turnover_24h: f64§first_id: Option<i64>§last_id: Option<i64>§count: Option<i64>§mark_price: f64§index_price: f64§open_interest: f64§open_interest_value: f64§single_open_interest: f64§funding_rate: f64§next_funding_time: Option<i64>§funding_interval_hour: f64§funding_cap: f64§basis: f64§basis_rate: f64§predicted_delivery_price: f64§delivery_time: Option<i64>§settlement_price: f64§funding_8h: f64§min_price: f64§max_price: f64§volume_notional: f64§last_qty: f64§interest_value: f64§last_trade_time: Option<i64>§open_time: Option<i64>§update_id: Option<i64>§state: Option<String>Instrument state string (“open”/“closed” etc.) — stored in blob.
Implementations§
Source§impl TickerFullPoint
impl TickerFullPoint
pub fn from_ticker(t: &Ticker) -> Self
Trait Implementations§
Source§impl Clone for TickerFullPoint
impl Clone for TickerFullPoint
Source§fn clone(&self) -> TickerFullPoint
fn clone(&self) -> TickerFullPoint
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl DataPoint for TickerFullPoint
impl DataPoint for TickerFullPoint
Source§const RECORD_SIZE: usize = FULL_SIZE
const RECORD_SIZE: usize = FULL_SIZE
Source§fn encode(&self, out: &mut [u8])
fn encode(&self, out: &mut [u8])
self to a fixed-size buffer (little-endian). Read moreSource§fn decode(bytes: &[u8]) -> Option<Self>
fn decode(bytes: &[u8]) -> Option<Self>
Source§fn timestamp_ms(&self) -> i64
fn timestamp_ms(&self) -> i64
Source§fn from_stream_event(ev: &StreamEvent) -> Option<Self>
fn from_stream_event(ev: &StreamEvent) -> Option<Self>
Self from a raw WS StreamEvent. Returns None if the
event doesn’t carry data for this class.Source§fn encode_blob(&self) -> Option<Vec<u8>>
fn encode_blob(&self) -> Option<Vec<u8>>
.blob file. Read more