Skip to main content

TextSubjectWindow

Struct TextSubjectWindow 

Source
pub struct TextSubjectWindow { /* private fields */ }
Expand description

One resolved (subject, graph) window, interned into the query dict.

Implementations§

Source§

impl TextSubjectWindow

Source

pub fn len(&self) -> usize

Distinct rows in the window.

Source

pub fn is_empty(&self) -> bool

Whether the window has no rows.

Source

pub fn has_graph(&self) -> bool

Whether the window carries the graph column.

Source

pub fn stored_ids(&self) -> usize

Ids the memo budget charges: one per subject, plus one per graph.

Source

pub fn contains_subject(&self, subject: &EncodedTerm) -> bool

Whether the window holds subject.

The probe road’s membership test: a pushed subject is looked up in the dict, then binary-searched in the sorted subject ids. A term the dict has never interned cannot be in the window.

Source

pub fn graphs_for( &self, subject: &EncodedTerm, ) -> Result<Vec<EncodedTerm>, ComputeError>

Graph terms for subject, in window order; empty when the request did not ask for the graph column or the subject is absent. An id that does not resolve is an ERROR: the subject form has no residual, so a lost graph must not silently drop the row.

Source

pub fn rows(&self) -> TextSubjectRows<'_>

Every row, decoded in bounded chunks (the keyless / driver execution).

Yields an error if a stored id does not resolve in the window’s dictionary. That cannot happen while the window holds the Arc (the dictionary never evicts), so the error exists to make a corrupt window fail the query instead of silently dropping a row — the subject form has no residual to recover it.

Trait Implementations§

Source§

impl Debug for TextSubjectWindow

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

§

impl<T> IntoRequest<T> for T

§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
§

impl<L> LayerExt<L> for L

§

fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>
where L: Layer<S>,

Applies the layer to a service and wraps it in [Layered].
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
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
§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,