pub struct CatalogEntry {Show 19 fields
pub id: String,
pub title: String,
pub name: Option<String>,
pub model: String,
pub created_at: DateTime<Utc>,
pub updated_at: DateTime<Utc>,
pub cost: f64,
pub message_count: Option<usize>,
pub compacted_into: Option<String>,
pub cwd: Option<PathBuf>,
pub profile: Option<String>,
pub turns: Option<usize>,
pub duration: Option<Duration>,
pub first_user: Option<String>,
pub last_user: Option<String>,
pub mtime: Option<SystemTime>,
pub bytes: u64,
pub has_journal: bool,
pub junk_id: bool,
/* private fields */
}Expand description
One past session as the Past tab sees it.
Fields§
§id: String§title: String§name: Option<String>§model: StringRaw model id as stored (anthropic/claude-opus-4-6).
created_at: DateTime<Utc>§updated_at: DateTime<Utc>§cost: f64§message_count: Option<usize>Header message_count (journal-overlaid). None for legacy files
that never persisted it — filled from the preview cache when known.
compacted_into: Option<String>Successor id when this session was compacted into another.
cwd: Option<PathBuf>Most recent start cwd.
profile: Option<String>§turns: Option<usize>Sum of end record turns, when any were recorded.
duration: Option<Duration>Sum of duration_ms (no writer emits it today — see Self::span).
first_user: Option<String>§last_user: Option<String>§mtime: Option<SystemTime>Newest of snapshot / journal mtime.
bytes: u64Snapshot + journal bytes.
has_journal: bool§junk_id: boolFile stem differs from header id, or the id is not YYYYMMDD-HHMMSS-xxxx.
Implementations§
Source§impl CatalogEntry
impl CatalogEntry
Sourcepub fn span(&self) -> TimeDelta
pub fn span(&self) -> TimeDelta
Wall-clock span created → updated (what the preview strip shows).
Sourcepub fn model_key(&self) -> &str
pub fn model_key(&self) -> &str
Normalised model key: provider prefix stripped (claude-opus-4-6).
Sourcepub fn model_label(&self) -> &str
pub fn model_label(&self) -> &str
Short model label (opus-4-6).
Sourcepub fn cwd_display(&self) -> Option<String>
pub fn cwd_display(&self) -> Option<String>
cwd with $HOME shown as ~ (~/Projects/x, ~ for home).
Trait Implementations§
Source§impl Clone for CatalogEntry
impl Clone for CatalogEntry
Source§fn clone(&self) -> CatalogEntry
fn clone(&self) -> CatalogEntry
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 Freeze for CatalogEntry
impl RefUnwindSafe for CatalogEntry
impl Send for CatalogEntry
impl Sync for CatalogEntry
impl Unpin for CatalogEntry
impl UnsafeUnpin for CatalogEntry
impl UnwindSafe for CatalogEntry
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,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
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