Class ConnectorSettings
- Namespace
- XeroxDev.YTMDesktop.Companion.Settings
- Assembly
- XeroxDev.YTMDesktop.Companion.dll
The settings for the connector.
public class ConnectorSettings
- Inheritance
-
ConnectorSettings
- Inherited Members
Constructors
ConnectorSettings(string, int, string, string, string, string)
The settings for the connector.
public ConnectorSettings(string host, int port, string appId, string appName, string appVersion, string token = null)
Parameters
hoststringThe host name of the server (has to be without a protocol like
http://orhttps://and can't have a trailing slash nor a port)
Hint: Some operating systems, such as Windows, may use an IPv6 address for localhost. This would result in a connection failure as the server is not listening on the IPv6 address.portintThe port of the server.
appIdstringThe id of your app. Must be all lowercase with only alphanumeric characters, no spaces and between 2 and 32 characters.
Regex:^[a-z0-9_\-]{2,32}$appNamestringThe name of your app. Must be between 2 and 48 characters.
appVersionstringThe version of your app. Must be semantic versioning compatible.
tokenstringThe token to connect to the server (if available).
Exceptions
- ArgumentNullException
Thrown when the host, app id or app name is null or empty.
- ArgumentException
Thrown when the host contains a protocol, a port, the app id is not valid or the app name is too short or too long.
Properties
AppId
The id of your app. Must be all lowercase with only alphanumeric characters, no spaces and between 2 and 32 characters.
Regex: ^[a-z0-9_\-]{2,32}$
public string AppId { get; set; }
Property Value
AppName
The name of your app. Must be between 2 and 48 characters.
public string AppName { get; set; }
Property Value
AppVersion
The version of your app. Must be semantic versioning compatible.
public string AppVersion { get; set; }
Property Value
Host
The host name of the server (has to be without a protocol like http:// or https:// and can't have a trailing slash nor a port)
Hint: Some operating systems, such as Windows, may use an IPv6 address for localhost. This would result in a connection failure as the server is not listening on the IPv6 address.
public string Host { get; set; }
Property Value
Port
The port of the server.
public int Port { get; set; }
Property Value
Token
The token to connect to the server (if available).
public string Token { get; set; }