Refactor WasmGateway struct and import statements

This commit is contained in:
bitfl0wer 2023-11-18 20:02:45 +01:00
parent 39e61a73e9
commit 6ae715988d
1 changed files with 11 additions and 1 deletions

View File

@ -1,6 +1,16 @@
pub use super::*;
use std::sync::Arc;
use super::events::Events;
use super::*;
use ws_stream_wasm::*;
use crate::types::{self, WebSocketEvent};
#[derive(Debug)]
pub struct WasmGateway {
events: Arc<Mutex<Events>>,
heartbeat_handler: HeartbeatHandler,
websocket_send: Arc<Mutex<SplitSink<WsStream, WsMessage>>>,
websocket_receive: SplitStream<WsStream>,
store: GatewayStore,
url: String,
}