MessageBuilder Class
Extends MessageBuilderBase
Module: opcua.miscellaneous
Constructor
MessageBuilder
(
-
options
Parameters:
-
options
Object-
securityMode
MessageSecurityModethe security Mode
-
[objectFactory=factories]
optionala object that provides a constructObject(id) method
-
Item Index
Methods
Methods
_append
(
private
-
message_chunk
append a message chunk
Parameters:
-
message_chunk
Object
_read_headers
(
Boolean
private
-
binaryStream
Parameters:
-
binaryStream
Object
Returns:
Boolean:
feed
(
-
data
Feed message builder with some data
Parameters:
-
data
Object
packet_analyzer
(
-
buffer
-
id
-
padding
-
offset
-
custom_options
Parameters:
-
buffer
Buffer -
id
Object -
padding
Integer -
offset
Integer -
custom_options
Object-
factory
Object-
constructObject
Function
-
-
Events
chunk
notify the observers that new message chunk has been received
Event Payload:
-
messageChunk
Bufferthe raw message chunk
error
notify the observers that an error has occurred
Event Payload:
-
error
Errorthe error to raise
full_message_body
notify the observers that a full message has been received
Event Payload:
-
full_message_body
Bufferthe full message body made of all concatenated chunks.
invalid_sequence_number
notify the observers that a message with an invalid sequence number has been received.
Event Payload:
-
expected
Numbersequence Number
-
actual
Numbersequence Number
message
notify the observers that a full message has been received
Event Payload:
-
objMessage
Objectthe decoded message object
-
msgType
Stringthe message type ( "HEL","ACK","OPN","CLO" or "MSG" )
-
the
Numberrequest Id
start_chunk
notify the observers that a new message is being built
Event Payload:
-
info
Object -
data
Object