pub struct Thread {
pub id: String,
/* private fields */
}Expand description
Synchronous thread handle.
Fields§
§id: StringImplementations§
Source§impl Thread
impl Thread
pub fn id(&self) -> &str
pub fn run(&self, input: impl Into<Input>) -> Result<TurnResult>
pub fn run_with( &self, input: impl Into<Input>, options: &TurnOptions, ) -> Result<TurnResult>
pub fn turn(&self, input: impl Into<Input>) -> Result<TurnHandle>
pub fn turn_with( &self, input: impl Into<Input>, options: &TurnOptions, ) -> Result<TurnHandle>
pub fn read(&self) -> Result<ThreadReadResponse>
pub fn read_with_turns(&self, include_turns: bool) -> Result<ThreadReadResponse>
pub fn set_name(&self, name: impl Into<String>) -> Result<ThreadSetNameResponse>
pub fn compact(&self) -> Result<ThreadCompactStartResponse>
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Thread
impl !UnwindSafe for Thread
impl Freeze for Thread
impl Send for Thread
impl Sync for Thread
impl Unpin for Thread
impl UnsafeUnpin for Thread
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