/// <summary> /// Update a Log Analytics workspace table. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. The name is case insensitive. /// </param> /// <param name='workspaceName'> /// The name of the workspace. /// </param> /// <param name='tableName'> /// The name of the table. /// </param> /// <param name='parameters'> /// The parameters required to update table properties. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <Table> BeginUpdateAsync(this ITablesOperations operations, string resourceGroupName, string workspaceName, string tableName, Table parameters, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.BeginUpdateWithHttpMessagesAsync(resourceGroupName, workspaceName, tableName, parameters, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Gets all the tables for the specified Log Analytics workspace. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. The name is case insensitive. /// </param> /// <param name='workspaceName'> /// The name of the workspace. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <IEnumerable <Table> > ListByWorkspaceAsync(this ITablesOperations operations, string resourceGroupName, string workspaceName, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.ListByWorkspaceWithHttpMessagesAsync(resourceGroupName, workspaceName, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Update or Create a Log Analytics workspace table. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. The name is case insensitive. /// </param> /// <param name='workspaceName'> /// The name of the workspace. /// </param> /// <param name='tableName'> /// The name of the table. /// </param> /// <param name='parameters'> /// The parameters required to update table properties. /// </param> public static Table CreateOrUpdate(this ITablesOperations operations, string resourceGroupName, string workspaceName, string tableName, Table parameters) { return(operations.CreateOrUpdateAsync(resourceGroupName, workspaceName, tableName, parameters).GetAwaiter().GetResult()); }
/// <summary> /// Delete a Log Analytics workspace table. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. The name is case insensitive. /// </param> /// <param name='workspaceName'> /// The name of the workspace. /// </param> /// <param name='tableName'> /// The name of the table. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task BeginDeleteAsync(this ITablesOperations operations, string resourceGroupName, string workspaceName, string tableName, CancellationToken cancellationToken = default(CancellationToken)) { (await operations.BeginDeleteWithHttpMessagesAsync(resourceGroupName, workspaceName, tableName, null, cancellationToken).ConfigureAwait(false)).Dispose(); }
/// <summary> /// Delete a Log Analytics workspace table. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. The name is case insensitive. /// </param> /// <param name='workspaceName'> /// The name of the workspace. /// </param> /// <param name='tableName'> /// The name of the table. /// </param> public static void BeginDelete(this ITablesOperations operations, string resourceGroupName, string workspaceName, string tableName) { operations.BeginDeleteAsync(resourceGroupName, workspaceName, tableName).GetAwaiter().GetResult(); }
/// <summary> /// Gets all the tables for the specified Log Analytics workspace. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. The name is case insensitive. /// </param> /// <param name='workspaceName'> /// The name of the workspace. /// </param> public static IEnumerable <Table> ListByWorkspace(this ITablesOperations operations, string resourceGroupName, string workspaceName) { return(operations.ListByWorkspaceAsync(resourceGroupName, workspaceName).GetAwaiter().GetResult()); }
/// <summary> /// Gets a Log Analytics workspace table. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. The name is case insensitive. /// </param> /// <param name='workspaceName'> /// The name of the workspace. /// </param> /// <param name='tableName'> /// The name of the table. /// </param> public static Table Get(this ITablesOperations operations, string resourceGroupName, string workspaceName, string tableName) { return(operations.GetAsync(resourceGroupName, workspaceName, tableName).GetAwaiter().GetResult()); }
/// <summary> /// Updates a Log Analytics workspace table properties. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. The name is case insensitive. /// </param> /// <param name='workspaceName'> /// The name of the workspace. /// </param> /// <param name='tableName'> /// The name of the table. /// </param> /// <param name='retentionInDays'> /// The data table data retention in days, between 30 and 730. Setting this /// property to null will default to the workspace retention. /// </param> public static Table Update(this ITablesOperations operations, string resourceGroupName, string workspaceName, string tableName, int?retentionInDays = default(int?)) { return(operations.UpdateAsync(resourceGroupName, workspaceName, tableName, retentionInDays).GetAwaiter().GetResult()); }