コード例 #1
0
 /// <summary>
 /// Creates the specified secret for use with external data sources in
 /// the specified database
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.Azure.Management.DataLake.AnalyticsCatalog.ICatalogOperations.
 /// </param>
 /// <param name='resourceGroupName'>
 /// Required. The name of the resourceGroup the Data Lake Analytics
 /// account is in
 /// </param>
 /// <param name='accountName'>
 /// Required. The name of the account to use
 /// </param>
 /// <param name='databaseName'>
 /// Required. The name of the database to create the secret in.
 /// </param>
 /// <param name='parameters'>
 /// Required. The parameters required to create the secret (name and
 /// password)
 /// </param>
 /// <returns>
 /// The create secret operation response.
 /// </returns>
 public static CatalogSecretCreateResponse CreateSecret(this ICatalogOperations operations, string resourceGroupName, string accountName, string databaseName, DataLakeAnalyticsCatalogSecretCreateOrUpdateParameters parameters)
 {
     return Task.Factory.StartNew((object s) => 
     {
         return ((ICatalogOperations)s).CreateSecretAsync(resourceGroupName, accountName, databaseName, parameters);
     }
     , operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult();
 }
コード例 #2
0
 /// <summary>
 /// Creates the specified secret for use with external data sources in
 /// the specified database
 /// </summary>
 /// <param name='operations'>
 /// Reference to the
 /// Microsoft.Azure.Management.DataLake.AnalyticsCatalog.ICatalogOperations.
 /// </param>
 /// <param name='resourceGroupName'>
 /// Required. The name of the resourceGroup the Data Lake Analytics
 /// account is in
 /// </param>
 /// <param name='accountName'>
 /// Required. The name of the account to use
 /// </param>
 /// <param name='databaseName'>
 /// Required. The name of the database to create the secret in.
 /// </param>
 /// <param name='parameters'>
 /// Required. The parameters required to create the secret (name and
 /// password)
 /// </param>
 /// <returns>
 /// The create secret operation response.
 /// </returns>
 public static Task<CatalogSecretCreateResponse> CreateSecretAsync(this ICatalogOperations operations, string resourceGroupName, string accountName, string databaseName, DataLakeAnalyticsCatalogSecretCreateOrUpdateParameters parameters)
 {
     return operations.CreateSecretAsync(resourceGroupName, accountName, databaseName, parameters, CancellationToken.None);
 }