StreamWorker Class

This is a Library topic for RemObjects SDK for .NET
This page is generated from external data, please do not update
Namespaces — Interfaces — Classes — Enums — Implements
Contents |
Overview
This class is used internally by ROZeroConfClient class to handle network communication with ROZeroConf_Hub encapsulating reading/writing socket stream and packing/unpacking data in a format required by ZeroConf protocol.
The class uses an internal binary format that is determined by ROZeroConf_Hub. A common request/response contains an operation name and a set of key-value pairs - operation parameters.
There is no need to use this class directly.
For internal use only.
Location
- Assembly: RemObjects.SDK.ZeroConf.dll
- Namespace: RemObjects.SDK.ZeroConfClient
Properties
| MaxLength |
|---|
|
A maximum size of data in one package. Default value is equal to 1MB.
|
| RemoteMaxLength |
|
The value of property is set during communication with ROZeroConf_Hub and shows the maximum package size that is set on the Hub.
|
| Stream |
|
Returns the socket stream that is used by the class instance to perform network communication.
|
| UserData |
|
not used.
|
Class Methods
| DecodePackage |
|---|
|
Unpacks binary data returned from ROZeroConf_Hub into the operation name and the array of key-pair values (operation parameters).
|
| EncodePackage |
|
Packs command from client (operation name and key-value pairs of parameters) to binary format.
|
| Int32FromBuffer |
|
Read 4 bytes from binary buffer and converts them to Int32 value.
|
Instance Methods
| constructor |
|---|
|
Creates an instance of an object, assigning callbacks and a socket stream to it.
|
| GenerateID |
|
Used to generate a new Id (integer value) to synchronize waiting requests with callbacks.
|
| SendControlPackage |
|
Sends a package with command and parameters to Hub. The first 4 bytes of the package are the length of entire package.
|
| SendData |
|
Sends previously packed data over the network stream. If stream is busy at the moment, it stores the binary package to the send queue.
|
| Start |
|
Starts network communication with Hub by sending "hello" package ROSW and and subscribes for a response. Method is called one time right after class instance creation. Further calls will be ignored.
|
See Also
- Lists
- RemObjects SDK for .NET: Namespaces — Interfaces — Classes — Enums — Implements
- RemObjects SDK shared: Data Types – File Types
- other editions
- RemObjects SDK for Xcode: Protocols — Classes — Enums — Aliases — Implements
- RemObjects SDK for Delphi: Interfaces — Classes — Aliases — Implements
- RemObjects SDK for Java: Namespaces — Interfaces — Classes — Enums — Implements
- RemObjects SDK for JavaScript: Objects

Product: RemObjects SDK
Available Editions: RemObjects SDK for .NET, Xcode, Delphi, Java and JavaScript