pub struct PageSignal {
pub partial: bool,
pub next_cursor: Option<String>,
pub scanned: Option<u64>,
pub covers_from: Option<String>,
}Expand description
What a bounded reply says about itself (RFC 05 §3.2, v1.31): the
envelope’s partial flag and the three fields that qualify it.
Derived, not serialized. The wire already carries the envelope
inside CallOutcome::Ok’s value; this is the renderer’s reading of
it, so it has no serde derive and no place in the pinned contract — a
script that wants the flag reads the reply it is in.
Some only when the reply is a JSON object carrying a boolean partial
— which is the envelope’s one required marker. A procedure that replies
with a bare list, a scalar, or TOML text (the introspect procedures) is
not paginated and gets no signal at all rather than a synthetic
partial: false: an absent envelope and a complete walk are different
facts, and the caller must not be told the second when only the first
is known.
Fields§
§partial: boolThe producer stopped before completing the walk — scan cap, tier coverage, time budget — and a short page is not the end.
next_cursor: Option<String>Non-null means more; null means the walk is complete for the
filter given. Opaque to the caller (a value cursor, never a
position).
scanned: Option<u64>Advisory: what the page cost, so an expensive empty page can be told from a cheap one. Omitted by procedures that do not count.
covers_from: Option<String>The oldest instant the answer could have covered, for a computed answer narrower than what was asked. Omitted by procedures with no notion of coverage.
Implementations§
Source§impl PageSignal
impl PageSignal
Sourcepub fn is_contract_violation(&self) -> bool
pub fn is_contract_violation(&self) -> bool
partial: true with next_cursor: null: the producer says it
stopped early and offers no way on. RFC 05 §3.2 names this a
contract violation an observer MAY report (RFC 13 §3); zenctl call says it as a caveat and does not move the exit code, because
a call is an act, not a judgement (#424).
Trait Implementations§
Source§impl Clone for PageSignal
impl Clone for PageSignal
Source§fn clone(&self) -> PageSignal
fn clone(&self) -> PageSignal
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 PageSignal
impl Debug for PageSignal
impl Eq for PageSignal
Source§impl PartialEq for PageSignal
impl PartialEq for PageSignal
impl StructuralPartialEq for PageSignal
Auto Trait Implementations§
impl Freeze for PageSignal
impl RefUnwindSafe for PageSignal
impl Send for PageSignal
impl Sync for PageSignal
impl Unpin for PageSignal
impl UnsafeUnpin for PageSignal
impl UnwindSafe for PageSignal
Blanket Implementations§
Source§impl<Source> AccessAs for Source
impl<Source> AccessAs for Source
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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