pub struct SessionStatsBuilder { /* private fields */ }Expand description
Builder pattern for SessionStats
Implementations§
Source§impl SessionStatsBuilder
impl SessionStatsBuilder
Sourcepub fn new(
session_id: Uuid,
created_at: DateTime<Utc>,
last_updated: DateTime<Utc>,
) -> Self
pub fn new( session_id: Uuid, created_at: DateTime<Utc>, last_updated: DateTime<Utc>, ) -> Self
Create a new builder with the required identity and timestamp fields.
Sourcepub fn with_context_sizes(self, hot: usize, warm: usize, cold: usize) -> Self
pub fn with_context_sizes(self, hot: usize, warm: usize, cold: usize) -> Self
Set the hot, warm, and cold context tier sizes.
Sourcepub fn with_counts(
self,
updates: usize,
entities: usize,
decisions: usize,
) -> Self
pub fn with_counts( self, updates: usize, entities: usize, decisions: usize, ) -> Self
Set total update, entity, and decision counts.
Sourcepub fn with_references(
self,
questions: usize,
concepts: usize,
code_refs: usize,
) -> Self
pub fn with_references( self, questions: usize, concepts: usize, code_refs: usize, ) -> Self
Set question, concept, and code reference counts.
Sourcepub fn build(self) -> SessionStats
pub fn build(self) -> SessionStats
Consume the builder and produce a SessionStats.
Auto Trait Implementations§
impl Freeze for SessionStatsBuilder
impl RefUnwindSafe for SessionStatsBuilder
impl Send for SessionStatsBuilder
impl Sync for SessionStatsBuilder
impl Unpin for SessionStatsBuilder
impl UnsafeUnpin for SessionStatsBuilder
impl UnwindSafe for SessionStatsBuilder
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
Mutably borrows from an owned value. Read more
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request