pub struct MessageRecord {
pub uuid: Option<String>,
pub parent_uuid: Option<Value>,
pub session_id: Option<String>,
pub timestamp: Option<String>,
pub cwd: Option<String>,
pub git_branch: Option<String>,
pub version: Option<String>,
pub message: Message,
}Fields§
§uuid: Option<String>§parent_uuid: Option<Value>§session_id: Option<String>§timestamp: Option<String>§cwd: Option<String>§git_branch: Option<String>§version: Option<String>§message: MessageImplementations§
Source§impl MessageRecord
impl MessageRecord
pub fn text_content(&self) -> String
pub fn tool_calls(&self) -> Vec<&str>
Sourcepub fn tool_input_content(&self) -> String
pub fn tool_input_content(&self) -> String
Extract only tool input content (the arguments passed to tools).
Sourcepub fn thinking_content(&self) -> String
pub fn thinking_content(&self) -> String
Extract only thinking block content.
Sourcepub fn text_content_no_thinking(&self) -> String
pub fn text_content_no_thinking(&self) -> String
Extract text content excluding thinking blocks.
Sourcepub fn touches_file(&self, path: &str) -> bool
pub fn touches_file(&self, path: &str) -> bool
Check if any tool input references a file path (substring match).
Trait Implementations§
Source§impl Debug for MessageRecord
impl Debug for MessageRecord
Source§impl<'de> Deserialize<'de> for MessageRecord
impl<'de> Deserialize<'de> for MessageRecord
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for MessageRecord
impl RefUnwindSafe for MessageRecord
impl Send for MessageRecord
impl Sync for MessageRecord
impl Unpin for MessageRecord
impl UnwindSafe for MessageRecord
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> 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>
Converts
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>
Converts
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