ChatClientRequestSpec

Trait ChatClientRequestSpec 

Source
pub trait ChatClientRequestSpec: Send + Sync {
    // Required methods
    fn call<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = impl CallResponseSpec> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn stream<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = impl StreamResponseSpec> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn user<T>(&mut self, text: T)
       where T: Into<Bytes>;
    fn system<T>(&mut self, text: T)
       where T: Into<Bytes>;
}

Required Methods§

Source

fn call<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = impl CallResponseSpec> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn stream<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = impl StreamResponseSpec> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn user<T>(&mut self, text: T)
where T: Into<Bytes>,

Source

fn system<T>(&mut self, text: T)
where T: Into<Bytes>,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§