Connection Class
Represents an (ongoing) connection between the device receiver and a particular device.
Namespace: MobileTrack.Receiver.ModelsAssembly: MobileTrack.Receiver (in MobileTrack.Receiver.exe) Version: 0.8+f6fd7a919db8417bc1e7bfd9b2ff9ab9586e296a
internal sealed class Connection : IDisposable
- Inheritance
- Object Connection
- Implements
- IDisposable
If the device loses the connection and later re-establishes it, a new Connection object will be created.
| Created |
When this connection was created
|
| Device |
The Device associated with this connection.
|
| EstablishConversation |
Whether the receiver must establish two-way conversation with the device.
|
| FromProtocolMessage |
Parser method to convert a message to a DeviceMessageDto, based on the protocol type
|
| GenerateProtocolCommand |
Generates a protocol command for the device, based on the protocol type.
|
| IsBusy |
Checks if actions are underway for the connection; if so, no new tasks may be assigned.
|
| LastActivity |
When the last activity (message or interaction) was received from the device.
|
| LastRead |
When the last message was read from the device.
|
| PendingCommands |
Queue of commands the device receiver has to sent back to the device.
|
| Dispose | Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. |
| ReadDataFromDevice |
Read the incoming message from the TCP stream.
|
| SendDataToDevice |
Send data back to the device.
|
| SetProtocol |
Sets the protocol for the connection
|
| SynchronizeDevice |
Synchronizes the values from a DeviceDto data structure and the actual device.
This method is invoked after the first handshake has been completed.
|