pub struct Socket { /* private fields */ }
Expand description
Defines the raw Socket type. This type should never be interacted with directly, except to create new instances of wrapper types.
Implementations§
source§impl Socket
impl Socket
sourcepub fn builder<T>(ctx: Arc<Context>) -> SocketBuilder<'static, T>where
T: IntoInnerSocket,
pub fn builder<T>(ctx: Arc<Context>) -> SocketBuilder<'static, T>where
T: IntoInnerSocket,
Start a new Socket Config builder
sourcepub fn inner(self) -> (Socket, EventedFile)
pub fn inner(self) -> (Socket, EventedFile)
Retrieve a Reference-Counted Pointer to self’s socket.
sourcepub fn from_sock_and_file(sock: Socket, file: EventedFile) -> Self
pub fn from_sock_and_file(sock: Socket, file: EventedFile) -> Self
Create a new socket from a given Sock and File
This assumes that sock
is already configured properly. Please don’t call this directly
unless you know what you’re doing.
Trait Implementations§
source§impl From<(Socket, PollEvented<ZmqFile>)> for Socket
impl From<(Socket, PollEvented<ZmqFile>)> for Socket
source§fn from((sock, file): (Socket, EventedFile)) -> Self
fn from((sock, file): (Socket, EventedFile)) -> Self
Converts to this type from the input type.
source§impl<T> InnerSocket<T> for Socketwhere
T: IntoInnerSocket + From<Self>,
impl<T> InnerSocket<T> for Socketwhere
T: IntoInnerSocket + From<Self>,
§type Request = MultipartRequest<T>
type Request = MultipartRequest<T>
The future that sends a multipart to a ZMQ socket
§type Response = MultipartResponse<T>
type Response = MultipartResponse<T>
The future that receives a multipart from a ZMQ socket
§type Sink = MultipartSink<T>
type Sink = MultipartSink<T>
A Sink that sends multiparts to a ZMQ socket
§type Stream = MultipartStream<T>
type Stream = MultipartStream<T>
A Stream of multiparts received from a ZMQ socket
§type SinkStream = MultipartSinkStream<T>
type SinkStream = MultipartSinkStream<T>
A Sink and Stream that sends and receives multiparts from a ZMQ socket