pub trait SessionAPI: BaseClient {
// Required methods
fn create_session(
&self,
) -> impl Future<Output = Result<Response<CreateSessionResponse>, Error>> + Send;
fn get_sessions<'a>(&'a self) -> GetSession<'a, Self>
where Self: Sized;
fn subscribe_chat(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send;
fn unsubscribe_chat(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send;
fn subscribe_donation(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send;
fn unsubscribe_donation(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send;
fn subscribe_subscription(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send;
fn unsubscribe_subscription(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send;
}Required Methods§
Sourcefn create_session(
&self,
) -> impl Future<Output = Result<Response<CreateSessionResponse>, Error>> + Send
fn create_session( &self, ) -> impl Future<Output = Result<Response<CreateSessionResponse>, Error>> + Send
Sourcefn get_sessions<'a>(&'a self) -> GetSession<'a, Self>where
Self: Sized,
fn get_sessions<'a>(&'a self) -> GetSession<'a, Self>where
Self: Sized,
Sourcefn subscribe_chat(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send
fn subscribe_chat( &self, session_key: &SessionKey, ) -> impl Future<Output = Result<(), Error>> + Send
Sourcefn unsubscribe_chat(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send
fn unsubscribe_chat( &self, session_key: &SessionKey, ) -> impl Future<Output = Result<(), Error>> + Send
Sourcefn subscribe_donation(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send
fn subscribe_donation( &self, session_key: &SessionKey, ) -> impl Future<Output = Result<(), Error>> + Send
Sourcefn unsubscribe_donation(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send
fn unsubscribe_donation( &self, session_key: &SessionKey, ) -> impl Future<Output = Result<(), Error>> + Send
Sourcefn subscribe_subscription(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send
fn subscribe_subscription( &self, session_key: &SessionKey, ) -> impl Future<Output = Result<(), Error>> + Send
Sourcefn unsubscribe_subscription(
&self,
session_key: &SessionKey,
) -> impl Future<Output = Result<(), Error>> + Send
fn unsubscribe_subscription( &self, session_key: &SessionKey, ) -> impl Future<Output = Result<(), Error>> + Send
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.