/// <summary> /// Returns a list of all scale unit nodes in a location. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of the resource group. /// </param> /// <param name='location'> /// Location of the resource. /// </param> /// <param name='odataQuery'> /// OData parameters to apply to the operation. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <IPage <ScaleUnitNode> > ListAsync(this IScaleUnitNodesOperations operations, string resourceGroupName, string location, ODataQuery <ScaleUnitNode> odataQuery = default(ODataQuery <ScaleUnitNode>), CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.ListWithHttpMessagesAsync(resourceGroupName, location, odataQuery, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Returns a list of all scale unit nodes in a location. /// </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 <ScaleUnitNode> > ListNextAsync(this IScaleUnitNodesOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.ListNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Return the requested scale unit node. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of the resource group. /// </param> /// <param name='location'> /// Location of the resource. /// </param> /// <param name='scaleUnitNode'> /// Name of the scale unit node. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <ScaleUnitNode> GetAsync(this IScaleUnitNodesOperations operations, string resourceGroupName, string location, string scaleUnitNode, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.GetWithHttpMessagesAsync(resourceGroupName, location, scaleUnitNode, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Power off a scale unit node. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of the resource group. /// </param> /// <param name='location'> /// Location of the resource. /// </param> /// <param name='scaleUnitNode'> /// Name of the scale unit node. /// </param> public static void PowerOff(this IScaleUnitNodesOperations operations, string resourceGroupName, string location, string scaleUnitNode) { operations.PowerOffAsync(resourceGroupName, location, scaleUnitNode).GetAwaiter().GetResult(); }
/// <summary> /// Returns a list of all scale unit nodes in a location. /// </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 <ScaleUnitNode> ListNext(this IScaleUnitNodesOperations operations, string nextPageLink) { return(operations.ListNextAsync(nextPageLink).GetAwaiter().GetResult()); }
/// <summary> /// Repairs a node of the cluster. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of the resource group. /// </param> /// <param name='location'> /// Location of the resource. /// </param> /// <param name='scaleUnitNode'> /// Name of the scale unit node. /// </param> /// <param name='bareMetalNode'> /// Description of a node. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task BeginRepairAsync(this IScaleUnitNodesOperations operations, string resourceGroupName, string location, string scaleUnitNode, BareMetalNodeDescription bareMetalNode, CancellationToken cancellationToken = default(CancellationToken)) { (await operations.BeginRepairWithHttpMessagesAsync(resourceGroupName, location, scaleUnitNode, bareMetalNode, null, cancellationToken).ConfigureAwait(false)).Dispose(); }
/// <summary> /// Shutdown a scale unit node. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of the resource group. /// </param> /// <param name='location'> /// Location of the resource. /// </param> /// <param name='scaleUnitNode'> /// Name of the scale unit node. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task ShutdownAsync(this IScaleUnitNodesOperations operations, string resourceGroupName, string location, string scaleUnitNode, CancellationToken cancellationToken = default(CancellationToken)) { (await operations.ShutdownWithHttpMessagesAsync(resourceGroupName, location, scaleUnitNode, null, cancellationToken).ConfigureAwait(false)).Dispose(); }
/// <summary> /// Repairs a node of the cluster. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of the resource group. /// </param> /// <param name='location'> /// Location of the resource. /// </param> /// <param name='scaleUnitNode'> /// Name of the scale unit node. /// </param> /// <param name='bareMetalNode'> /// Description of a node. /// </param> public static void BeginRepair(this IScaleUnitNodesOperations operations, string resourceGroupName, string location, string scaleUnitNode, BareMetalNodeDescription bareMetalNode) { operations.BeginRepairAsync(resourceGroupName, location, scaleUnitNode, bareMetalNode).GetAwaiter().GetResult(); }
/// <summary> /// Stop maintenance mode for a scale unit node. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of the resource group. /// </param> /// <param name='location'> /// Location of the resource. /// </param> /// <param name='scaleUnitNode'> /// Name of the scale unit node. /// </param> public static void BeginStopMaintenanceMode(this IScaleUnitNodesOperations operations, string resourceGroupName, string location, string scaleUnitNode) { operations.BeginStopMaintenanceModeAsync(resourceGroupName, location, scaleUnitNode).GetAwaiter().GetResult(); }
/// <summary> /// Shutdown a scale unit node. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of the resource group. /// </param> /// <param name='location'> /// Location of the resource. /// </param> /// <param name='scaleUnitNode'> /// Name of the scale unit node. /// </param> public static void BeginShutdown(this IScaleUnitNodesOperations operations, string resourceGroupName, string location, string scaleUnitNode) { operations.BeginShutdownAsync(resourceGroupName, location, scaleUnitNode).GetAwaiter().GetResult(); }
/// <summary> /// Returns a list of all scale unit nodes in a location. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of the resource group. /// </param> /// <param name='location'> /// Location of the resource. /// </param> /// <param name='odataQuery'> /// OData parameters to apply to the operation. /// </param> public static IPage <ScaleUnitNode> List(this IScaleUnitNodesOperations operations, string resourceGroupName, string location, ODataQuery <ScaleUnitNode> odataQuery = default(ODataQuery <ScaleUnitNode>)) { return(operations.ListAsync(resourceGroupName, location, odataQuery).GetAwaiter().GetResult()); }
/// <summary> /// Return the requested scale unit node. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// Name of the resource group. /// </param> /// <param name='location'> /// Location of the resource. /// </param> /// <param name='scaleUnitNode'> /// Name of the scale unit node. /// </param> public static ScaleUnitNode Get(this IScaleUnitNodesOperations operations, string resourceGroupName, string location, string scaleUnitNode) { return(operations.GetAsync(resourceGroupName, location, scaleUnitNode).GetAwaiter().GetResult()); }