C# Class BACnet.IP.ForeignDevicePort

Inheritance: IPort, IDisposable
ファイルを表示 Open project: LorenVS/bacstack

Public Methods

Method Description
Dispose ( ) : void

Disposes of the foreign device port

ForeignDevicePort ( ForeignDevicePortOptions options ) : System

Constructs a new foreign device port instance

HandleMessage ( IMessage message ) : bool

Handles a message queued on this session.

Open ( ) : void

Opens the foreign device port

Resolve ( IEnumerable processes ) : void

Resolves the port's dependencies

SendNetgram ( OutboundNetgram netgram ) : void

Sends a netgram out of this port

Private Methods

Method Description
_createBbmdMac ( ) : void

Creates the bbmd mac address

_createInboundNetgram ( Mac mac, byte buffer, int offset, int length ) : NetgramReceivedMessage

Creates an inbound netgram

_createMessage ( FunctionCode function ) : IBvlcMessage

Creates a new bvlc message based on a function code

_createServer ( ) : void

Creates the udp socket

_disposeAll ( ) : void

Disposes all of the resources held by an open port, in preparation for transitioning back to a closed state

_onDatagramReceived ( IPEndPoint ep, byte buffer, int length ) : void

Called whenever a datagram is received

_processMessage ( Mac mac, IBvlcMessage message, byte buffer, int offset, int length ) : NetgramReceivedMessage

Processes a received bvlc message

_processResult ( Mac mac, ResultCode code ) : void

Processes a received result message

_register ( object state ) : void

Registers the foreign device with the remote bbmd

_requireState ( State state ) : void

Checks to make sure that the port is in state

_sendMessage ( Mac mac, IBvlcMessage message ) : void

Sends a bvlc message

_startRegistering ( ) : void

Begins registration of the foreign device with the BBMD

Method Details

Dispose() public method

Disposes of the foreign device port
public Dispose ( ) : void
return void

ForeignDevicePort() public method

Constructs a new foreign device port instance
public ForeignDevicePort ( ForeignDevicePortOptions options ) : System
options ForeignDevicePortOptions The options to create the port with
return System

HandleMessage() public method

Handles a message queued on this session.
public HandleMessage ( IMessage message ) : bool
message IMessage The message to handle
return bool

Open() public method

Opens the foreign device port
public Open ( ) : void
return void

Resolve() public method

Resolves the port's dependencies
public Resolve ( IEnumerable processes ) : void
processes IEnumerable The processes
return void

SendNetgram() public method

Sends a netgram out of this port
public SendNetgram ( OutboundNetgram netgram ) : void
netgram BACnet.Core.Datalink.OutboundNetgram The netgram to send
return void