[−][src]Trait basws_server::ServerLogic
Associated Types
type Request: Serialize + DeserializeOwned + Clone + Send + Sync + Debug
type Response: Serialize + DeserializeOwned + Clone + Send + Sync + Debug
type Client: Send + Sync + Debug
type Account: Identifiable<Id = Self::AccountId> + Send + Sync + Debug
type AccountId: Copy + Hash + Eq + Send + Sync
Required methods
#[must_use]fn handle_request<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
client: &'life1 ConnectedClient<Self>,
request: Self::Request,
server: &'life2 Server<Self>
) -> Pin<Box<dyn Future<Output = Result<RequestHandling<Self::Response>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
&'life0 self,
client: &'life1 ConnectedClient<Self>,
request: Self::Request,
server: &'life2 Server<Self>
) -> Pin<Box<dyn Future<Output = Result<RequestHandling<Self::Response>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Self: 'async_trait,
#[must_use]fn lookup_account_from_installation_id<'life0, 'async_trait>(
&'life0 self,
installation_id: Uuid
) -> Pin<Box<dyn Future<Output = Result<Option<Handle<Self::Account>>>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
&'life0 self,
installation_id: Uuid
) -> Pin<Box<dyn Future<Output = Result<Option<Handle<Self::Account>>>> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
fn protocol_version_requirements(&self) -> VersionReq
#[must_use]fn lookup_or_create_installation<'life0, 'life1, 'async_trait>(
&'life0 self,
client: &'life1 ConnectedClient<Self>,
installation_id: Option<Uuid>
) -> Pin<Box<dyn Future<Output = Result<InstallationConfig>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
&'life0 self,
client: &'life1 ConnectedClient<Self>,
installation_id: Option<Uuid>
) -> Pin<Box<dyn Future<Output = Result<InstallationConfig>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
#[must_use]fn client_reconnected<'life0, 'life1, 'async_trait>(
&'life0 self,
client: &'life1 ConnectedClient<Self>
) -> Pin<Box<dyn Future<Output = Result<RequestHandling<Self::Response>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
&'life0 self,
client: &'life1 ConnectedClient<Self>
) -> Pin<Box<dyn Future<Output = Result<RequestHandling<Self::Response>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
#[must_use]fn new_client_connected<'life0, 'life1, 'async_trait>(
&'life0 self,
client: &'life1 ConnectedClient<Self>
) -> Pin<Box<dyn Future<Output = Result<RequestHandling<Self::Response>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
&'life0 self,
client: &'life1 ConnectedClient<Self>
) -> Pin<Box<dyn Future<Output = Result<RequestHandling<Self::Response>>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
Provided methods
#[must_use]fn account_associated<'life0, 'life1, 'async_trait>(
&'life0 self,
_client: &'life1 ConnectedClient<Self>
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
&'life0 self,
_client: &'life1 ConnectedClient<Self>
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>> where
'life0: 'async_trait,
'life1: 'async_trait,
Self: 'async_trait,
#[must_use]fn handle_websocket_error<'life0, 'async_trait>(
&'life0 self,
_err: Error
) -> Pin<Box<dyn Future<Output = ErrorHandling> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,
&'life0 self,
_err: Error
) -> Pin<Box<dyn Future<Output = ErrorHandling> + Send + 'async_trait>> where
'life0: 'async_trait,
Self: 'async_trait,