Skip to main content

SkillMessageWriter

Struct SkillMessageWriter 

Source
pub struct SkillMessageWriter<W> { /* private fields */ }
Expand description

Writes binary-framed skill messages to a stream.

Implementations§

Source§

impl<W: AsyncWrite + Unpin> SkillMessageWriter<W>

Source

pub fn new(writer: W) -> Self

Source

pub async fn write_execute(&mut self, payload: &ExecutePayload) -> Result<()>

Source

pub async fn write_cancel(&mut self, execution_id: &str) -> Result<()>

Source

pub async fn write_stdin_data( &mut self, payload: &StdinDataPayload, ) -> Result<()>

Source

pub async fn write_resize(&mut self, payload: &ResizePayload) -> Result<()>

Source

pub async fn write_signal(&mut self, payload: &SignalPayload) -> Result<()>

Source

pub async fn write_start_session( &mut self, payload: &StartSessionPayload, ) -> Result<()>

Source

pub async fn write_shutdown(&mut self) -> Result<()>

Source

pub async fn write_ack(&mut self, payload: &AckPayload) -> Result<()>

Source

pub async fn write_stdout_chunk( &mut self, payload: &DataChunkPayload, ) -> Result<()>

Source

pub async fn write_stderr_chunk( &mut self, payload: &DataChunkPayload, ) -> Result<()>

Source

pub async fn write_progress(&mut self, payload: &ProgressPayload) -> Result<()>

Source

pub async fn write_completed( &mut self, payload: &CompletedPayload, ) -> Result<()>

Source

pub async fn write_error(&mut self, payload: &ErrorPayload) -> Result<()>

Source

pub async fn write_session_started( &mut self, payload: &SessionStartedPayload, ) -> Result<()>

Source

pub async fn write_proxy_submit( &mut self, payload: &ProxySubmitPayload, ) -> Result<()>

Source

pub async fn write_proxy_cancel(&mut self, proxy_id: &str) -> Result<()>

Source

pub async fn write_proxy_stdout_chunk( &mut self, payload: &ProxyChunkPayload, ) -> Result<()>

Source

pub async fn write_proxy_stderr_chunk( &mut self, payload: &ProxyChunkPayload, ) -> Result<()>

Source

pub async fn write_proxy_completed( &mut self, payload: &ProxyCompletedPayload, ) -> Result<()>

Source

pub async fn write_proxy_rejected( &mut self, payload: &ProxyRejectedPayload, ) -> Result<()>

Auto Trait Implementations§

§

impl<W> Freeze for SkillMessageWriter<W>
where W: Freeze,

§

impl<W> RefUnwindSafe for SkillMessageWriter<W>
where W: RefUnwindSafe,

§

impl<W> Send for SkillMessageWriter<W>
where W: Send,

§

impl<W> Sync for SkillMessageWriter<W>
where W: Sync,

§

impl<W> Unpin for SkillMessageWriter<W>
where W: Unpin,

§

impl<W> UnsafeUnpin for SkillMessageWriter<W>
where W: UnsafeUnpin,

§

impl<W> UnwindSafe for SkillMessageWriter<W>
where W: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.