public RentController( IRentRepository rentRepository, ICopterRepository copterRepository, IIoTHub hub) { _rentRepository = rentRepository; _copterRepository = copterRepository; _hub = hub; }
private void SendDataToCloud() { var data = new { //Receber dados e enviar. }; IIoTHub.SendData(data, deviceKey); }
public ChequeController( IChequeRepository chequeRepository, IReportRenderer reportRenderer, IMailBox mailBox, IIoTHub hub, ICopterRepository copterRepository) { _chequeRepository = chequeRepository; _reportRenderer = reportRenderer; _copterRepository = copterRepository; _mailBox = mailBox; _hub = hub; }
/// <summary> /// Create sdk factory /// </summary> /// <param name="hub">Outer hub abstraction</param> /// <param name="config">Module framework configuration</param> public IoTHubClientFactory(IIoTHub hub, IModuleConfig config) { _hub = hub ?? throw new ArgumentNullException(nameof(hub)); if (string.IsNullOrEmpty(config.EdgeHubConnectionString)) { throw new InvalidConfigurationException( "Must have connection string or module id to create clients."); } var cs = IotHubConnectionStringBuilder.Create(config.EdgeHubConnectionString); if (string.IsNullOrEmpty(cs.DeviceId)) { throw new InvalidConfigurationException( "Connection string is not a device or module connection string."); } DeviceId = cs.DeviceId; ModuleId = cs.ModuleId; }
/// <summary> /// Create Registry /// </summary> public SqlQuery(IIoTHub hub, IJsonSerializer serializer) { _hub = hub; _serializer = serializer; }
/// <summary> /// Create Registry /// </summary> public SqlQuery(IIoTHub hub) { _hub = hub; }
public Facade(IApiWrapper apiWrapper, IIoTHub iotHub) { this._apiWrapper = apiWrapper; this._iotHub = iotHub; }
public ActivityService(IConfiguration configuration, IIoTHub ioTHub) { this.Configuration = configuration; this.IoTHub = ioTHub; }
public Facade(IApiWrapper apiWrapper, IIoTHub iotHub, ILockerPiApiWrapper lockerWrapper) { this._apiWrapper = apiWrapper; this._iotHub = iotHub; this._lockerWrapper = lockerWrapper; }
private async void InitIoTHub() { deviceKey = await IIoTHub.AddDeviceAsync(App.deviceName); }