Struct rings_node::backend::Backend
source · pub struct Backend { /* private fields */ }Expand description
A Backend struct contains http_server.
Implementations§
Trait Implementations§
source§impl MessageCallback for Backend
impl MessageCallback for Backend
source§fn custom_message<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
handler: &'life1 MessageHandler,
ctx: &'life2 MessagePayload<Message>,
msg: &'life3 MaybeEncrypted<CustomMessage>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn custom_message<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 self,
handler: &'life1 MessageHandler,
ctx: &'life2 MessagePayload<Message>,
msg: &'life3 MaybeEncrypted<CustomMessage>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
custom_message in Backend for now only handle
the Message::CustomMessage in handler invoke_callback function.
And send http request to localhost through Backend http_request handler.
source§fn builtin_message<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_handler: &'life1 MessageHandler,
_ctx: &'life2 MessagePayload<Message>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn builtin_message<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
_handler: &'life1 MessageHandler,
_ctx: &'life2 MessagePayload<Message>
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Message handler for builtin message