diff --git a/src/ws/client/mod.rs b/src/ws/client/mod.rs index 0dbf081c6..12c7229b9 100644 --- a/src/ws/client/mod.rs +++ b/src/ws/client/mod.rs @@ -4,7 +4,7 @@ mod service; pub use self::connect::Connect; pub use self::error::ClientError; -pub use self::service::Client; +pub use self::service::{Client, DefaultClient}; #[derive(PartialEq, Hash, Debug, Clone, Copy)] pub(crate) enum Protocol { diff --git a/src/ws/client/service.rs b/src/ws/client/service.rs index ab0e48035..8e97b743d 100644 --- a/src/ws/client/service.rs +++ b/src/ws/client/service.rs @@ -19,6 +19,9 @@ use ws::Codec; use super::{ClientError, Connect, Protocol}; +/// Default client, uses default connector. +pub type DefaultClient = Client>; + /// WebSocket's client pub struct Client where diff --git a/src/ws/mod.rs b/src/ws/mod.rs index b5a667084..1fbbd03dd 100644 --- a/src/ws/mod.rs +++ b/src/ws/mod.rs @@ -18,7 +18,7 @@ mod proto; mod service; mod transport; -pub use self::client::{Client, ClientError, Connect}; +pub use self::client::{Client, ClientError, Connect, DefaultClient}; pub use self::codec::{Codec, Frame, Message}; pub use self::frame::Parser; pub use self::proto::{CloseCode, CloseReason, OpCode};