pub struct OpenCodeSession { /* private fields */ }Trait Implementations§
Source§impl Session for OpenCodeSession
impl Session for OpenCodeSession
Source§fn turn_stream(
&mut self,
input: Input,
options: TurnOptions,
) -> Pin<Box<dyn Future<Output = Result<EventStream>> + Send + '_>>
fn turn_stream( &mut self, input: Input, options: TurnOptions, ) -> Pin<Box<dyn Future<Output = Result<EventStream>> + Send + '_>>
Run a turn and return a stream of events.
Source§fn session_id(&self) -> Option<&str>
fn session_id(&self) -> Option<&str>
Session ID (populated after the first turn completes).
Source§fn interrupt(&mut self) -> Pin<Box<dyn Future<Output = Result<()>> + Send + '_>>
fn interrupt(&mut self) -> Pin<Box<dyn Future<Output = Result<()>> + Send + '_>>
Interrupt the current turn. No-op if idle.
Source§fn turn(
&mut self,
input: Input,
options: TurnOptions,
) -> Pin<Box<dyn Future<Output = Result<TurnOutput, AgentError>> + Send + '_>>
fn turn( &mut self, input: Input, options: TurnOptions, ) -> Pin<Box<dyn Future<Output = Result<TurnOutput, AgentError>> + Send + '_>>
Run a turn and return the buffered result. Read more
Auto Trait Implementations§
impl Freeze for OpenCodeSession
impl !RefUnwindSafe for OpenCodeSession
impl Send for OpenCodeSession
impl Sync for OpenCodeSession
impl Unpin for OpenCodeSession
impl UnsafeUnpin for OpenCodeSession
impl !UnwindSafe for OpenCodeSession
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