/** * * @param id The device Id * @param scopeId Scope Id of the application * @param authenticationType Type of authentication: It can be Group symmetric * key, Device SAS key or x.509 * @param options Value for authentication: keys for symmetric and * SAS key authentication or x.509 certificate */ public IoTCClient(string id, string scopeId, IoTCConnect authenticationType, object options) { Logger = new ConsoleLogger(); Id = id; ScopeId = scopeId; AuthenticationType = authenticationType; if (AuthenticationType == IoTCConnect.SYMM_KEY || AuthenticationType == IoTCConnect.DEVICE_KEY) { SasKey = (string)options; } else if (this.AuthenticationType == IoTCConnect.X509_CERT) { Certificate = (IoTCentralCert)options; } callbacks = new Dictionary <IoTCEvents, Delegate>(); }
public IoTCClient(string id, string modelId, string scopeId, IoTCConnect authenticationType, object options) : this(id, scopeId, authenticationType, options) { ModelId = modelId; }
/** * * @param id The device Id * @param scopeId Scope Id of the application * @param authenticationType Type of authentication: It can be Group symmetric * key, Device SAS key or x.509 * @param options Value for authentication: keys for symmetric and * SAS key authentication or x.509 certificate * @param logger A custom logger implementing the ILogger interface */ public IoTCClient(string id, string scopeId, IoTCConnect authenticationType, object options, ILogger logger) : this(id, scopeId, authenticationType, options) { Logger = logger; }