pub struct BinanceContinuousKline {
pub subscription_id: SubscriptionId,
pub kline: BinanceKlineData,
}Expand description
BinanceFuturesUsdMarket real-time continuous-contract
(perpetual) kline message.
Differs from the spot BinanceKline shape: the symbol is the top-level ps (pair) and
ct (contract type), and the inner k object has no s field.
§Raw Payload Example
See docs: https://binance-docs.github.io/apidocs/futures/en/#continuous-contract-kline-candlestick-streams
{
"e": "continuous_kline",
"E": 1607443058651,
"ps": "BTCUSDT",
"ct": "PERPETUAL",
"k": {
"t": 1607443020000, "T": 1607443079999, "i": "1m", "f": 116467658886,
"L": 116468012423, "o": "18787.00", "c": "18804.04", "h": "18804.04",
"l": "18786.54", "v": "197.664", "n": 543, "x": false, "q": "3715253.19494",
"V": "184.769", "Q": "3472925.84746", "B": "0"
}
}Fields§
§subscription_id: SubscriptionIdInstrument-map routing key {channel}|{MARKET} (e.g.
_perpetual@continuousKline_1m|BTCUSDT), baked at deserialize from the top-level pair
(ps) and the inner interval (k.i) by reusing
ExchangeSub::id — the single source of truth shared with
subscribe-time key construction. The continuous payload has no k.s, so the pair is the
only symbol source. The channel prefix is hardcoded perpetual (_perpetual@): the wire
ct (contract type) is intentionally not deserialized, since the
_perpetual@continuousKline_ subscription this model decodes only ever receives PERPETUAL
frames. A non-perpetual frame (impossible given the subscription) would build a
non-matching key and be dropped at the instrument-map lookup rather than mis-attributed.
kline: BinanceKlineDataTrait Implementations§
Source§impl Clone for BinanceContinuousKline
impl Clone for BinanceContinuousKline
Source§fn clone(&self) -> BinanceContinuousKline
fn clone(&self) -> BinanceContinuousKline
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for BinanceContinuousKline
impl Debug for BinanceContinuousKline
Source§impl<'de> Deserialize<'de> for BinanceContinuousKline
impl<'de> Deserialize<'de> for BinanceContinuousKline
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 Identifier<Option<SubscriptionId>> for BinanceContinuousKline
impl Identifier<Option<SubscriptionId>> for BinanceContinuousKline
fn id(&self) -> Option<SubscriptionId>
Source§impl PartialEq for BinanceContinuousKline
impl PartialEq for BinanceContinuousKline
Source§fn eq(&self, other: &BinanceContinuousKline) -> bool
fn eq(&self, other: &BinanceContinuousKline) -> bool
self and other values to be equal, and is used by ==.Source§impl PartialOrd for BinanceContinuousKline
impl PartialOrd for BinanceContinuousKline
impl StructuralPartialEq for BinanceContinuousKline
Auto Trait Implementations§
impl Freeze for BinanceContinuousKline
impl RefUnwindSafe for BinanceContinuousKline
impl Send for BinanceContinuousKline
impl Sync for BinanceContinuousKline
impl Unpin for BinanceContinuousKline
impl UnsafeUnpin for BinanceContinuousKline
impl UnwindSafe for BinanceContinuousKline
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more