示例#1
0
 /// <summary>
 /// Create or update a storage insight.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.Azure.Management.OperationalInsights.IStorageInsightOperations.
 /// </param>
 /// <param name='resourceGroupName'>
 /// Required. The resource group name of the storage insight.
 /// </param>
 /// <param name='workspaceName'>
 /// Required. The name of the parent workspace that will contain the
 /// storage insight
 /// </param>
 /// <param name='parameters'>
 /// Required. The parameters required to create or update a storage
 /// insight.
 /// </param>
 /// <returns>
 /// The create or update storage insight operation response.
 /// </returns>
 public static StorageInsightCreateOrUpdateResponse CreateOrUpdate(this IStorageInsightOperations operations, string resourceGroupName, string workspaceName, StorageInsightCreateOrUpdateParameters parameters)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IStorageInsightOperations)s).CreateOrUpdateAsync(resourceGroupName, workspaceName, parameters);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
示例#2
0
 /// <summary>
 /// Gets the next page of storage insight instances with the link to
 /// the next page.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.Azure.Management.OperationalInsights.IStorageInsightOperations.
 /// </param>
 /// <param name='nextLink'>
 /// Required. The url to the next storage insights page.
 /// </param>
 /// <returns>
 /// The list storage insights operation response.
 /// </returns>
 public static StorageInsightListResponse ListNext(this IStorageInsightOperations operations, string nextLink)
 {
     return(Task.Factory.StartNew((object s) =>
     {
         return ((IStorageInsightOperations)s).ListNextAsync(nextLink);
     }
                                  , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
 /// <summary>
 /// Initializes a new instance of the
 /// OperationalInsightsManagementClient class.
 /// </summary>
 /// <param name='httpClient'>
 /// The Http client
 /// </param>
 public OperationalInsightsManagementClient(HttpClient httpClient)
     : base(httpClient)
 {
     this._storageInsights = new StorageInsightOperations(this);
     this._workspaces      = new WorkspaceOperations(this);
     this._apiVersion      = "2015-03-20";
     this._longRunningOperationInitialTimeout = -1;
     this._longRunningOperationRetryTimeout   = -1;
     this.HttpClient.Timeout = TimeSpan.FromSeconds(120);
 }
示例#4
0
 /// <summary>
 /// Initializes a new instance of the
 /// OperationalInsightsManagementClient class.
 /// </summary>
 public OperationalInsightsManagementClient()
     : base()
 {
     this._dataSources     = new DataSourceOperations(this);
     this._linkedServices  = new LinkedServiceOperations(this);
     this._search          = new SearchOperations(this);
     this._storageInsights = new StorageInsightOperations(this);
     this._workspaces      = new WorkspaceOperations(this);
     this._apiVersion      = "2015-03-20";
     this._longRunningOperationInitialTimeout = -1;
     this._longRunningOperationRetryTimeout   = -1;
     this.HttpClient.Timeout = TimeSpan.FromSeconds(120);
 }
示例#5
0
 /// <summary>
 /// Create or update a storage insight.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.Azure.Management.OperationalInsights.IStorageInsightOperations.
 /// </param>
 /// <param name='resourceGroupName'>
 /// Required. The resource group name of the storage insight.
 /// </param>
 /// <param name='workspaceName'>
 /// Required. The name of the parent workspace that will contain the
 /// storage insight
 /// </param>
 /// <param name='parameters'>
 /// Required. The parameters required to create or update a storage
 /// insight.
 /// </param>
 /// <returns>
 /// The create or update storage insight operation response.
 /// </returns>
 public static Task <StorageInsightCreateOrUpdateResponse> CreateOrUpdateAsync(this IStorageInsightOperations operations, string resourceGroupName, string workspaceName, StorageInsightCreateOrUpdateParameters parameters)
 {
     return(operations.CreateOrUpdateAsync(resourceGroupName, workspaceName, parameters, CancellationToken.None));
 }
示例#6
0
 /// <summary>
 /// Gets the next page of storage insight instances with the link to
 /// the next page.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.Azure.Management.OperationalInsights.IStorageInsightOperations.
 /// </param>
 /// <param name='nextLink'>
 /// Required. The url to the next storage insights page.
 /// </param>
 /// <returns>
 /// The list storage insights operation response.
 /// </returns>
 public static Task <StorageInsightListResponse> ListNextAsync(this IStorageInsightOperations operations, string nextLink)
 {
     return(operations.ListNextAsync(nextLink, CancellationToken.None));
 }
示例#7
0
 /// <summary>
 /// Gets the first page of storage insight instances in a workspace
 /// with the link to the next page.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.Azure.Management.OperationalInsights.IStorageInsightOperations.
 /// </param>
 /// <param name='resourceGroupName'>
 /// Required. The resource group name of the storage insights.
 /// </param>
 /// <param name='workspaceName'>
 /// Required. The workspace that contains the storage insights.
 /// </param>
 /// <returns>
 /// The list storage insights operation response.
 /// </returns>
 public static Task <StorageInsightListResponse> ListInWorkspaceAsync(this IStorageInsightOperations operations, string resourceGroupName, string workspaceName)
 {
     return(operations.ListInWorkspaceAsync(resourceGroupName, workspaceName, CancellationToken.None));
 }
示例#8
0
 /// <summary>
 /// Deletes a storage insight instance.
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.Azure.Management.OperationalInsights.IStorageInsightOperations.
 /// </param>
 /// <param name='resourceGroupName'>
 /// Required. The resource group name of the storage insight.
 /// </param>
 /// <param name='workspaceName'>
 /// Required. The name of the workspace that contains the storage
 /// insight.
 /// </param>
 /// <param name='storageInsightName'>
 /// Required. The name of the storage insight.
 /// </param>
 /// <returns>
 /// A standard service response including an HTTP status code and
 /// request ID.
 /// </returns>
 public static Task <AzureOperationResponse> DeleteAsync(this IStorageInsightOperations operations, string resourceGroupName, string workspaceName, string storageInsightName)
 {
     return(operations.DeleteAsync(resourceGroupName, workspaceName, storageInsightName, CancellationToken.None));
 }