Class ProtocolBase
- Namespace
- OpenGSQ
- Assembly
- OpenGSQ.dll
Abstract base class for protocols.
public abstract class ProtocolBase
- Inheritance
-
ProtocolBase
- Derived
- Inherited Members
Constructors
ProtocolBase(string, int, int)
Initializes a new instance of the ProtocolBase class.
public ProtocolBase(string host, int port, int timeout = 5000)
Parameters
host
stringThe host to connect to.
port
intThe port to connect to.
timeout
intThe connection timeout in milliseconds. Default is 5 seconds.
Properties
FullName
Gets the full name of the protocol.
public abstract string FullName { get; }
Property Value
Host
Gets the host to connect to.
public string Host { get; }
Property Value
Port
Gets the port to connect to.
public int Port { get; }
Property Value
Timeout
The timeout for the connection in seconds.
public int Timeout { get; }
Property Value
Methods
GetIPAddress()
Retrieves the IP address of the host.
protected Task<string> GetIPAddress()