/// <summary> /// List environment setting in a given lab. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='labAccountName'> /// The name of the lab Account. /// </param> /// <param name='labName'> /// The name of the lab. /// </param> /// <param name='odataQuery'> /// OData parameters to apply to the operation. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <IPage <EnvironmentSetting> > ListAsync(this IEnvironmentSettingsOperations operations, string resourceGroupName, string labAccountName, string labName, ODataQuery <EnvironmentSetting> odataQuery = default(ODataQuery <EnvironmentSetting>), CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.ListWithHttpMessagesAsync(resourceGroupName, labAccountName, labName, odataQuery, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// List environment setting in a given lab. /// </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 <EnvironmentSetting> > ListNextAsync(this IEnvironmentSettingsOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.ListNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Create or replace an existing Environment Setting. This operation can take /// a while to complete /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='labAccountName'> /// The name of the lab Account. /// </param> /// <param name='labName'> /// The name of the lab. /// </param> /// <param name='environmentSettingName'> /// The name of the environment Setting. /// </param> /// <param name='environmentSetting'> /// Represents settings of an environment, from which environment instances /// would be created /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <EnvironmentSetting> BeginCreateOrUpdateAsync(this IEnvironmentSettingsOperations operations, string resourceGroupName, string labAccountName, string labName, string environmentSettingName, EnvironmentSetting environmentSetting, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.BeginCreateOrUpdateWithHttpMessagesAsync(resourceGroupName, labAccountName, labName, environmentSettingName, environmentSetting, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Get environment setting /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='labAccountName'> /// The name of the lab Account. /// </param> /// <param name='labName'> /// The name of the lab. /// </param> /// <param name='environmentSettingName'> /// The name of the environment Setting. /// </param> /// <param name='expand'> /// Specify the $expand query. Example: 'properties($select=publishingState)' /// </param> public static EnvironmentSetting Get(this IEnvironmentSettingsOperations operations, string resourceGroupName, string labAccountName, string labName, string environmentSettingName, string expand = default(string)) { return(operations.GetAsync(resourceGroupName, labAccountName, labName, environmentSettingName, expand).GetAwaiter().GetResult()); }
/// <summary> /// List environment setting in a given lab. /// </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 <EnvironmentSetting> ListNext(this IEnvironmentSettingsOperations operations, string nextPageLink) { return(operations.ListNextAsync(nextPageLink).GetAwaiter().GetResult()); }
/// <summary> /// Starts a template by starting all resources inside the template. This /// operation can take a while to complete /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='labAccountName'> /// The name of the lab Account. /// </param> /// <param name='labName'> /// The name of the lab. /// </param> /// <param name='environmentSettingName'> /// The name of the environment Setting. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task BeginStopAsync(this IEnvironmentSettingsOperations operations, string resourceGroupName, string labAccountName, string labName, string environmentSettingName, CancellationToken cancellationToken = default(CancellationToken)) { (await operations.BeginStopWithHttpMessagesAsync(resourceGroupName, labAccountName, labName, environmentSettingName, null, cancellationToken).ConfigureAwait(false)).Dispose(); }
/// <summary> /// Starts a template by starting all resources inside the template. This /// operation can take a while to complete /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='labAccountName'> /// The name of the lab Account. /// </param> /// <param name='labName'> /// The name of the lab. /// </param> /// <param name='environmentSettingName'> /// The name of the environment Setting. /// </param> public static void BeginStop(this IEnvironmentSettingsOperations operations, string resourceGroupName, string labAccountName, string labName, string environmentSettingName) { operations.BeginStopAsync(resourceGroupName, labAccountName, labName, environmentSettingName).GetAwaiter().GetResult(); }
/// <summary> /// Create or replace an existing Environment Setting. This operation can take /// a while to complete /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='labAccountName'> /// The name of the lab Account. /// </param> /// <param name='labName'> /// The name of the lab. /// </param> /// <param name='environmentSettingName'> /// The name of the environment Setting. /// </param> /// <param name='environmentSetting'> /// Represents settings of an environment, from which environment instances /// would be created /// </param> public static EnvironmentSetting BeginCreateOrUpdate(this IEnvironmentSettingsOperations operations, string resourceGroupName, string labAccountName, string labName, string environmentSettingName, EnvironmentSetting environmentSetting) { return(operations.BeginCreateOrUpdateAsync(resourceGroupName, labAccountName, labName, environmentSettingName, environmentSetting).GetAwaiter().GetResult()); }
/// <summary> /// List environment setting in a given lab. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='labAccountName'> /// The name of the lab Account. /// </param> /// <param name='labName'> /// The name of the lab. /// </param> /// <param name='odataQuery'> /// OData parameters to apply to the operation. /// </param> public static IPage <EnvironmentSetting> List(this IEnvironmentSettingsOperations operations, string resourceGroupName, string labAccountName, string labName, ODataQuery <EnvironmentSetting> odataQuery = default(ODataQuery <EnvironmentSetting>)) { return(operations.ListAsync(resourceGroupName, labAccountName, labName, odataQuery).GetAwaiter().GetResult()); }
/// <summary> /// Provisions/deprovisions required resources for an environment setting based /// on current state of the lab/environment setting. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. /// </param> /// <param name='labAccountName'> /// The name of the lab Account. /// </param> /// <param name='labName'> /// The name of the lab. /// </param> /// <param name='environmentSettingName'> /// The name of the environment Setting. /// </param> /// <param name='publishPayload'> /// Payload for Publish operation on EnvironmentSetting. /// </param> public static void Publish(this IEnvironmentSettingsOperations operations, string resourceGroupName, string labAccountName, string labName, string environmentSettingName, PublishPayload publishPayload) { operations.PublishAsync(resourceGroupName, labAccountName, labName, environmentSettingName, publishPayload).GetAwaiter().GetResult(); }