OSDP.Net 5.2.1
A .NET library for implementing the Open Supervised Device Protocol (OSDP)
Loading...
Searching...
No Matches
IOsdpConnection.cs
1using System;
2using System.Threading;
3using System.Threading.Tasks;
4
6{
10 public interface IOsdpConnection : IDisposable
11 {
13 int BaudRate { get; }
14
18 bool IsOpen { get; }
19
23 TimeSpan ReplyTimeout { get; set; }
24
28 Task Open();
29
33 Task Close();
34
39 Task WriteAsync(byte[] buffer);
40
47 Task<int> ReadAsync(byte[] buffer, CancellationToken token);
48 }
49}
Defines a connection for communicating via OSDP protocol.
Task< int > ReadAsync(byte[] buffer, CancellationToken token)
Read from connection.
TimeSpan ReplyTimeout
Timeout value waiting for a reply.
Task WriteAsync(byte[] buffer)
Write to connection.
Task Close()
Close the connection for communications.
int BaudRate
Speed of the connection.
bool IsOpen
Is the connection open and ready to communicate.
Task Open()
Open the connection for communications.