pub struct HistoryCommand;Expand description
Show conversation history (spec-068 §13.6).
/history (no argument): the last [session.resume] expand_default_lines messages,
sliced before formatting (INV-SP-6). /history N: the last N messages. /history all:
pages through the full history in expand_default_lines-sized chunks — never
materializes the full history before formatting — with an explicit “may take a moment”
notice before the first page. /history next: continues from the pagination cursor left
by a prior /history all or /history next.
Output is sent via crate::sink::ChannelSink::send_transcript, not the handle
return value, so channels with a structured display buffer (TUI) can backfill per-entry
instead of flattening to one string.
Trait Implementations§
Source§impl CommandHandler<CommandContext<'_>> for HistoryCommand
impl CommandHandler<CommandContext<'_>> for HistoryCommand
Source§fn name(&self) -> &'static str
fn name(&self) -> &'static str
Command name including the leading slash, e.g.
"/help". Read moreSource§fn description(&self) -> &'static str
fn description(&self) -> &'static str
One-line description shown in
/help output.Source§fn args_hint(&self) -> &'static str
fn args_hint(&self) -> &'static str
Argument hint shown after the command name in help, e.g.
"[path]". Read moreSource§fn category(&self) -> SlashCategory
fn category(&self) -> SlashCategory
Category for grouping in
/help.Source§fn requires_auth(&self) -> bool
fn requires_auth(&self) -> bool
Returns
true if this command requires a trusted (local) caller. Read moreSource§fn handle<'a>(
&'a self,
ctx: &'a mut CommandContext<'_>,
args: &'a str,
) -> Pin<Box<dyn Future<Output = Result<CommandOutput, CommandError>> + Send + 'a>>
fn handle<'a>( &'a self, ctx: &'a mut CommandContext<'_>, args: &'a str, ) -> Pin<Box<dyn Future<Output = Result<CommandOutput, CommandError>> + Send + 'a>>
Execute the command. Read more
Source§fn feature_gate(&self) -> Option<&'static str>
fn feature_gate(&self) -> Option<&'static str>
Feature gate label, if this command is conditionally compiled.
Auto Trait Implementations§
impl Freeze for HistoryCommand
impl RefUnwindSafe for HistoryCommand
impl Send for HistoryCommand
impl Sync for HistoryCommand
impl Unpin for HistoryCommand
impl UnsafeUnpin for HistoryCommand
impl UnwindSafe for HistoryCommand
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