pub struct QotRightCache { /* private fields */ }Implementations§
Source§impl QotRightCache
impl QotRightCache
pub fn reconnect_lifecycle_snapshot(&self) -> QotRightReconnectLifecycle
pub fn register_reconnect_pending( &self, expected_generation: u64, contribution: QotRightReconnectAccumulator, ) -> Option<QotRightReconnectRegistration>
pub fn reserve_reconnect_deferred( &self, expected_generation: u64, contribution: QotRightReconnectAccumulator, ) -> Option<QotRightReconnectRegistration>
pub fn deferred_reconnect_is_active( &self, token: QotRightReconnectToken, generation: u64, ) -> bool
Sourcepub fn admit_deferred_reconnect_dispatch(
&self,
token: QotRightReconnectToken,
generation: u64,
) -> bool
pub fn admit_deferred_reconnect_dispatch( &self, token: QotRightReconnectToken, generation: u64, ) -> bool
Linearize a Subscribe CMD6211 writer admission against entitlement
pushes. A push that moved the exact owner to Pending before this call
wins and rejects the send. Once the first CMD6211 command is admitted,
later same-generation pushes merge into the deferred owner without
disconnecting the route before its ACK transaction completes.
pub fn reconnect_claim_is_active( &self, token: QotRightReconnectToken, generation: u64, ) -> bool
pub fn pending_reconnect_is_active( &self, token: QotRightReconnectToken, generation: u64, ) -> bool
Sourcepub fn freeze_reconnect_request_claim(
&self,
token: QotRightReconnectToken,
generation: u64,
) -> Option<QotRightReconnectClaim>
pub fn freeze_reconnect_request_claim( &self, token: QotRightReconnectToken, generation: u64, ) -> Option<QotRightReconnectClaim>
Freeze the active reconnect accumulator at request-send time. Delayed
entitlement follow-ups absorb every contribution received during the
1s C++ spacing window into the serving request; contributions arriving
after this transaction remain in follow_up for the next generation.
pub fn commit_deferred_reconnect_after_ack<T>( &self, token: QotRightReconnectToken, generation: u64, commit: impl FnOnce() -> T, ) -> Option<T>
pub fn fail_deferred_reconnect( &self, token: QotRightReconnectToken, generation: u64, ) -> bool
Sourcepub fn begin_reconnect_handoff(&self) -> QotRightReconnectHandoff
pub fn begin_reconnect_handoff(&self) -> QotRightReconnectHandoff
Freeze the exact source-generation reconnect owner before any socket retry begins. An ordinary transport failure creates an empty Pending owner; late same-generation entitlement pushes merge into that owner. The successor connection must present this token when claiming the handoff, so an unrelated reconnect loop cannot consume it.
pub fn advance_generation_and_claim_reconnect( &self, handoff: QotRightReconnectHandoff, active_generation: u64, ) -> Option<QotRightReconnectClaim>
pub fn finish_reconnect( &self, token: QotRightReconnectToken, generation: u64, ) -> Option<QotRightReconnectRegistration>
Source§impl QotRightCache
impl QotRightCache
pub fn new() -> Self
pub fn get(&self) -> QotRightData
pub fn refresh_current_facts(&self) -> QotRightRefreshCurrentFacts
pub fn freshness(&self) -> QotRightFreshness
pub fn is_fresh(&self) -> bool
pub fn meta_snapshot(&self) -> QotRightStateMeta
pub fn take_event_contract_category_preload_request(&self) -> bool
pub fn set_orderbook_depths( &self, hk_option_depth: Option<u32>, hk_future_depth: Option<u32>, )
pub fn mark_stale(&self, reason: &str)
pub fn advance_login_epoch(&self, new_epoch: u64, user_id: Option<u64>)
pub fn advance_backend_generation(&self, new_generation: u64)
pub fn mark_pending(&self)
pub fn mark_pending_if_generation(&self, expected_generation: u64) -> bool
pub fn mark_fresh(&self)
pub fn mark_failed(&self, error: impl Into<String>)
pub fn mark_failed_if_generation( &self, expected_generation: u64, error: impl Into<String>, ) -> bool
pub fn last_refresh_at_ms(&self) -> i64
pub fn set_pushed_quote_change_notify(&self, notify: PushedQuoteChangeNotify)
pub fn pushed_quote_change_notify(&self) -> Option<PushedQuoteChangeNotify>
pub fn pushed_quote_change_notify_snapshot( &self, ) -> (u64, Option<PushedQuoteChangeNotify>)
pub fn apply_6651_changes(&self, items: &[(i32, i32, i32)]) -> Vec<i32>
pub fn apply_direct_auth_changes(&self, items: &[(i32, u32)]) -> Vec<i32>
Sourcepub fn update_from_backend(
&self,
update: QotRightBackendUpdate,
) -> QotRightBackendApplyOutcome
pub fn update_from_backend( &self, update: QotRightBackendUpdate, ) -> QotRightBackendApplyOutcome
从后端 CMD 6024 响应更新权限数据.
v1.4.106 codex 1217 F2 [P1] (5月1日): us_future_detail 子字段存在 =
覆盖 (含值=0). 之前 if cme > 0 跳过 0 让 LV1 → 0 (No) 实质降级被
silent 保留;但 C++ 逐个 has_open_api_*_auth() 判断,父字段存在不代表
未返回的子市场可按 0 覆盖。
v1.4.106 codex 1217 F1: apply 成功后自动 mark Fresh.
pub fn update_from_backend_if_generation( &self, facts: QotRightFullApplyFacts, update: QotRightBackendUpdate, ) -> Option<QotRightBackendApplyOutcome>
pub fn update_quotas_from_backend_if_generation( &self, expected_generation: u64, update: QotRightBackendUpdate, ) -> Option<QotRightBackendApplyOutcome>
Trait Implementations§
Source§impl Clone for QotRightCache
impl Clone for QotRightCache
Source§fn clone(&self) -> QotRightCache
fn clone(&self) -> QotRightCache
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl !RefUnwindSafe for QotRightCache
impl !UnwindSafe for QotRightCache
impl Freeze for QotRightCache
impl Send for QotRightCache
impl Sync for QotRightCache
impl Unpin for QotRightCache
impl UnsafeUnpin for QotRightCache
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> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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