/// <summary> /// Initializes device with the <see cref="IDeviceServiceChannel"/> interface. /// </summary> /// <param name="serviceChannel">Service channel used to communicate with the DeviceHive service.</param> public virtual void Initialize(IDeviceServiceChannel serviceChannel) { if (serviceChannel == null) { throw new ArgumentNullException("serviceChannel"); } ServiceChannel = serviceChannel; }
/// <summary> /// Initializes device with the <see cref="IDeviceServiceChannel"/> interface. /// Also sets device status to "Online". /// </summary> /// <param name="serviceChannel">Service channel used to communicate with the DeviceHive service.</param> public virtual void Initialize(IDeviceServiceChannel serviceChannel) { if (serviceChannel == null) throw new ArgumentNullException("serviceChannel"); ServiceChannel = serviceChannel; Status = "Online"; }