/// <summary>
 /// Gets a KPI in the hub.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='hubName'>
 /// The name of the hub.
 /// </param>
 /// <param name='kpiName'>
 /// The name of the KPI.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <KpiResourceFormatInner> GetAsync(this IKpiOperations operations, string resourceGroupName, string hubName, string kpiName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetWithHttpMessagesAsync(resourceGroupName, hubName, kpiName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemple #2
0
 /// <summary>
 /// Creates a KPI or updates an existing KPI in the hub.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='hubName'>
 /// The name of the hub.
 /// </param>
 /// <param name='kpiName'>
 /// The name of the KPI.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the create/update KPI operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <KpiResourceFormat> CreateOrUpdateAsync(this IKpiOperations operations, string resourceGroupName, string hubName, string kpiName, KpiResourceFormat parameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CreateOrUpdateWithHttpMessagesAsync(resourceGroupName, hubName, kpiName, parameters, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemple #3
0
 /// <summary>
 /// Gets all the KPIs in the specified hub.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <KpiResourceFormat> > ListByHubNextAsync(this IKpiOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListByHubNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Deletes a KPI in the hub.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='hubName'>
 /// The name of the hub.
 /// </param>
 /// <param name='kpiName'>
 /// The name of the KPI.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task DeleteAsync(this IKpiOperations operations, string resourceGroupName, string hubName, string kpiName, CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.DeleteWithHttpMessagesAsync(resourceGroupName, hubName, kpiName, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }
Exemple #5
0
 /// <summary>
 /// Gets a KPI in the hub.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='hubName'>
 /// The name of the hub.
 /// </param>
 /// <param name='kpiName'>
 /// The name of the KPI.
 /// </param>
 public static KpiResourceFormat Get(this IKpiOperations operations, string resourceGroupName, string hubName, string kpiName)
 {
     return(operations.GetAsync(resourceGroupName, hubName, kpiName).GetAwaiter().GetResult());
 }
Exemple #6
0
 /// <summary>
 /// Creates a KPI or updates an existing KPI in the hub.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='hubName'>
 /// The name of the hub.
 /// </param>
 /// <param name='kpiName'>
 /// The name of the KPI.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the create/update KPI operation.
 /// </param>
 public static KpiResourceFormat CreateOrUpdate(this IKpiOperations operations, string resourceGroupName, string hubName, string kpiName, KpiResourceFormat parameters)
 {
     return(operations.CreateOrUpdateAsync(resourceGroupName, hubName, kpiName, parameters).GetAwaiter().GetResult());
 }
Exemple #7
0
 /// <summary>
 /// Gets all the KPIs in the specified hub.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 public static IPage <KpiResourceFormat> ListByHubNext(this IKpiOperations operations, string nextPageLink)
 {
     return(operations.ListByHubNextAsync(nextPageLink).GetAwaiter().GetResult());
 }
Exemple #8
0
 /// <summary>
 /// Deletes a KPI in the hub.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='hubName'>
 /// The name of the hub.
 /// </param>
 /// <param name='kpiName'>
 /// The name of the KPI.
 /// </param>
 public static void BeginDelete(this IKpiOperations operations, string resourceGroupName, string hubName, string kpiName)
 {
     operations.BeginDeleteAsync(resourceGroupName, hubName, kpiName).GetAwaiter().GetResult();
 }
Exemple #9
0
 /// <summary>
 /// Gets all the KPIs in the specified hub.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='hubName'>
 /// The name of the hub.
 /// </param>
 public static IPage <KpiResourceFormat> ListByHub(this IKpiOperations operations, string resourceGroupName, string hubName)
 {
     return(operations.ListByHubAsync(resourceGroupName, hubName).GetAwaiter().GetResult());
 }
Exemple #10
0
 /// <summary>
 /// Reprocesses the Kpi values of the specified KPI.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='hubName'>
 /// The name of the hub.
 /// </param>
 /// <param name='kpiName'>
 /// The name of the KPI.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task ReprocessAsync(this IKpiOperations operations, string resourceGroupName, string hubName, string kpiName, CancellationToken cancellationToken = default(CancellationToken))
 {
     await operations.ReprocessWithHttpMessagesAsync(resourceGroupName, hubName, kpiName, null, cancellationToken).ConfigureAwait(false);
 }
Exemple #11
0
 /// <summary>
 /// Reprocesses the Kpi values of the specified KPI.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='hubName'>
 /// The name of the hub.
 /// </param>
 /// <param name='kpiName'>
 /// The name of the KPI.
 /// </param>
 public static void Reprocess(this IKpiOperations operations, string resourceGroupName, string hubName, string kpiName)
 {
     operations.ReprocessAsync(resourceGroupName, hubName, kpiName).GetAwaiter().GetResult();
 }