C# Class Microsoft.Azure.Devices.Applications.RemoteMonitoring.DeviceAdmin.Infrastructure.Repository.AlertsRepository

An IAlertsRepository implementation with functionality for accessing Alerts-related data.
Inheritance: IAlertsRepository
Mostra file Open project: Azure/azure-iot-remote-monitoring Class Usage Examples

Public Methods

Method Description
AlertsRepository ( IConfigurationProvider configProvider, IBlobStorageClientFactory blobStorageClientFactory ) : Microsoft.Azure.Devices.Applications.RemoteMonitoring.Common.Configurations

Initializes a new instance of the AlertsRepository class.

LoadLatestAlertHistoryAsync ( System.DateTime minTime, int minResults ) : Task>

Loads the latest Device Alert History items.

Private Methods

Method Description
BuildModelForItem ( string ruleOutput, string deviceId, string value, string time ) : Microsoft.Azure.Devices.Applications.RemoteMonitoring.DeviceAdmin.Infrastructure.Models.AlertHistoryItemModel
ProduceAlertHistoryItem ( System.Dynamic.ExpandoObject expandoObject ) : Microsoft.Azure.Devices.Applications.RemoteMonitoring.DeviceAdmin.Infrastructure.Models.AlertHistoryItemModel
ProduceAlertHistoryItemsAsync ( Stream stream ) : List

Method Details

AlertsRepository() public method

Initializes a new instance of the AlertsRepository class.
public AlertsRepository ( IConfigurationProvider configProvider, IBlobStorageClientFactory blobStorageClientFactory ) : Microsoft.Azure.Devices.Applications.RemoteMonitoring.Common.Configurations
configProvider IConfigurationProvider /// The IConfigurationProvider implementation with which the new /// instance will be initialized. ///
blobStorageClientFactory IBlobStorageClientFactory
return Microsoft.Azure.Devices.Applications.RemoteMonitoring.Common.Configurations

LoadLatestAlertHistoryAsync() public method

Loads the latest Device Alert History items.
public LoadLatestAlertHistoryAsync ( System.DateTime minTime, int minResults ) : Task>
minTime System.DateTime /// The cutoff time for Device Alert History items that should be returned. ///
minResults int /// The minimum number of items that should be returned, if possible, /// after or otherwise. ///
return Task>