C# 클래스 NetMQ.Devices.DeviceBase

A DeviceBase forwards messages received by a front-end socket to a back-end socket, from which they are then sent, and can contain a Poller.
상속: IDevice
파일 보기 프로젝트 열기: NetMQ/NetMQ3-x

보호된 프로퍼티들

프로퍼티 타입 설명
BackendSocket NetMQSocket
FrontendSocket NetMQSocket

공개 메소드들

메소드 설명
Initialize ( ) : void

Configure the frontend and backend sockets and then Start this device.

Run ( ) : void

Initiate operation of the Poller associated with this device, if this device owns it. This also sets IsRunning to true.

Start ( ) : void
Stop ( bool waitForCloseToComplete = true ) : void

Stop the device and safely close the underlying sockets.

보호된 메소드들

메소드 설명
BackendHandler ( object sender, NetMQSocketEventArgs args ) : void

Invoked when a message has been received by the backend socket.

DeviceBase ( INetMQPoller poller, [ frontendSocket, [ backendSocket, DeviceMode mode ) : System

Create a new instance of the DeviceBase class.

DeviceBase ( NetMQSocket frontendSocket, NetMQSocket backendSocket, DeviceMode mode ) : System

Create a new instance of the DeviceBase class.

FrontendHandler ( object sender, NetMQSocketEventArgs args ) : void

Invoked when a message has been received by the frontend socket.

메소드 상세

BackendHandler() 보호된 메소드

Invoked when a message has been received by the backend socket.
protected BackendHandler ( object sender, NetMQSocketEventArgs args ) : void
sender object the object that raised the ReceiveReady event
args NetMQSocketEventArgs a NetMQSocketEventArgs that contains a Socket for receiving data from
리턴 void

DeviceBase() 보호된 메소드

Create a new instance of the DeviceBase class.
frontendSocket must not be null. backendSocket must not be null.
protected DeviceBase ( INetMQPoller poller, [ frontendSocket, [ backendSocket, DeviceMode mode ) : System
poller INetMQPoller the to use for detecting when messages are available
frontendSocket [ /// A that will pass incoming messages to . ///
backendSocket [ /// A that will receive messages from (and optionally send replies to) . ///
mode DeviceMode the (either Blocking or Threaded) for this device
리턴 System

DeviceBase() 보호된 메소드

Create a new instance of the DeviceBase class.
protected DeviceBase ( NetMQSocket frontendSocket, NetMQSocket backendSocket, DeviceMode mode ) : System
frontendSocket NetMQSocket /// A that will pass incoming messages to . ///
backendSocket NetMQSocket /// A that will receive messages from (and optionally send replies to) . ///
mode DeviceMode the (either Blocking or Threaded) for this device
리턴 System

FrontendHandler() 보호된 추상적인 메소드

Invoked when a message has been received by the frontend socket.
protected abstract FrontendHandler ( object sender, NetMQSocketEventArgs args ) : void
sender object the object that raised the ReceiveReady event
args NetMQSocketEventArgs a NetMQSocketEventArgs that contains a Socket for receiving data from
리턴 void

Initialize() 공개 메소드

Configure the frontend and backend sockets and then Start this device.
public Initialize ( ) : void
리턴 void

Run() 공개 메소드

Initiate operation of the Poller associated with this device, if this device owns it. This also sets IsRunning to true.
public Run ( ) : void
리턴 void

Start() 공개 메소드

public Start ( ) : void
리턴 void

Stop() 공개 메소드

Stop the device and safely close the underlying sockets.
public Stop ( bool waitForCloseToComplete = true ) : void
waitForCloseToComplete bool If true, this method will block until the /// underlying poller is fully stopped. Defaults to true.
리턴 void

프로퍼티 상세

BackendSocket 보호되어 있는 프로퍼티

The backend socket that will normally receive messages from (and possibly send replies to) FrontendSocket.
protected NetMQSocket BackendSocket
리턴 NetMQSocket

FrontendSocket 보호되어 있는 프로퍼티

The frontend socket that will normally pass messages to BackendSocket.
protected NetMQSocket FrontendSocket
리턴 NetMQSocket