Skip to content

Commit 42d4aa6

Browse files
Maddie Claytonazdevxps
authored andcommitted
Add ResourceGroupCompleter to MachineLearning
1 parent cc2c48d commit 42d4aa6

13 files changed

+27
-0
lines changed

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/CommitmentPlans/GetAzureMLCommitmentAssociation.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
using System.Management.Automation;
1616
using Microsoft.Azure.Management.MachineLearning.CommitmentPlans.Models;
1717
using Microsoft.Rest.Azure;
18+
using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters;
1819

1920
namespace Microsoft.Azure.Commands.MachineLearning
2021
{
@@ -24,6 +25,7 @@ namespace Microsoft.Azure.Commands.MachineLearning
2425
public class GetAzureMLCommitmentAssociation : CommitmentPlansCmdletBase
2526
{
2627
[Parameter(Mandatory = true, HelpMessage = "The name of the resource group for the Azure ML commitment association.")]
28+
[ResourceGroupCompleter]
2729
[ValidateNotNullOrEmpty]
2830
public string ResourceGroupName { get; set; }
2931

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/CommitmentPlans/GetAzureMLCommitmentPlan.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,15 @@
1717

1818
namespace Microsoft.Azure.Commands.MachineLearning
1919
{
20+
using ResourceManager.Common.ArgumentCompleters;
2021
using Rest.Azure;
2122

2223
[Cmdlet(VerbsCommon.Get, CommitmentPlansCmdletBase.CommitmentPlanCommandletSuffix)]
2324
[OutputType(typeof(CommitmentPlan), typeof(CommitmentPlan[]))]
2425
public class GetAzureMLCommitmentPlan : CommitmentPlansCmdletBase
2526
{
2627
[Parameter(Mandatory = false, HelpMessage = "The name of the resource group for the Azure ML commitment plan.")]
28+
[ResourceGroupCompleter]
2729
[ValidateNotNullOrEmpty]
2830
public string ResourceGroupName { get; set; }
2931

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/CommitmentPlans/GetAzureMLCommitmentPlanUsageHistory.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,15 @@
1717

1818
namespace Microsoft.Azure.Commands.MachineLearning
1919
{
20+
using ResourceManager.Common.ArgumentCompleters;
2021
using Rest.Azure;
2122

2223
[Cmdlet(VerbsCommon.Get, CommitmentPlansCmdletBase.CommitmentPlanUsageHistorySuffix)]
2324
[OutputType(typeof(PlanUsageHistory[]))]
2425
public class GetAzureMLCommitmentPlanUsageHistory : CommitmentPlansCmdletBase
2526
{
2627
[Parameter(Mandatory = true, HelpMessage = "The name of the resource group for the Azure ML commitment plan.")]
28+
[ResourceGroupCompleter]
2729
[ValidateNotNullOrEmpty]
2830
public string ResourceGroupName { get; set; }
2931

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/CommitmentPlans/MoveAzureMLCommitmentAssociation.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
using System.Collections.Generic;
1616
using System.Management.Automation;
1717
using Microsoft.Azure.Management.MachineLearning.CommitmentPlans.Models;
18+
using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters;
1819

1920
namespace Microsoft.Azure.Commands.MachineLearning
2021
{
@@ -23,6 +24,7 @@ namespace Microsoft.Azure.Commands.MachineLearning
2324
public class MoveAzureMLCommitmentAssociation : CommitmentPlansCmdletBase
2425
{
2526
[Parameter(Mandatory = true, HelpMessage = "The name of the resource group for the Azure ML commitment association.")]
27+
[ResourceGroupCompleter]
2628
[ValidateNotNullOrEmpty]
2729
public string ResourceGroupName { get; set; }
2830

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/CommitmentPlans/NewAzureMLCommitmentPlan.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
using Microsoft.WindowsAzure.Commands.Common;
1717
using Microsoft.Azure.Management.MachineLearning.CommitmentPlans.Models;
1818
using Microsoft.Azure.Commands.Common.Authentication.Abstractions;
19+
using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters;
1920

2021
namespace Microsoft.Azure.Commands.MachineLearning.Cmdlets
2122
{
@@ -25,6 +26,7 @@ namespace Microsoft.Azure.Commands.MachineLearning.Cmdlets
2526
public class NewAzureMLCommitmentPlan : CommitmentPlansCmdletBase
2627
{
2728
[Parameter(Mandatory = true, HelpMessage = "The name of the resource group for the Azure ML commitment plan.")]
29+
[ResourceGroupCompleter]
2830
[ValidateNotNullOrEmpty]
2931
public string ResourceGroupName { get; set; }
3032

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/CommitmentPlans/RemoveAzureMLCommitmentPlan.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ namespace Microsoft.Azure.Commands.MachineLearning
2121
using Management.MachineLearning.CommitmentPlans.Models;
2222
using Utilities;
2323
using Common.Authentication.Abstractions;
24+
using ResourceManager.Common.ArgumentCompleters;
25+
2426
[Cmdlet(VerbsCommon.Remove, CommitmentPlansCmdletBase.CommitmentPlanCommandletSuffix, SupportsShouldProcess = true)]
2527
[OutputType(typeof(void))]
2628
public class RemoveAzureMLCommitmentPlan : CommitmentPlansCmdletBase
@@ -32,6 +34,7 @@ public class RemoveAzureMLCommitmentPlan : CommitmentPlansCmdletBase
3234
ParameterSetName = RemoveAzureMLCommitmentPlan.RemoveByNameGroupParameterSet,
3335
Mandatory = true,
3436
HelpMessage = "The name of the resource group for the Azure ML commitment plan.")]
37+
[ResourceGroupCompleter]
3538
[ValidateNotNullOrEmpty]
3639
public string ResourceGroupName { get; set; }
3740

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/CommitmentPlans/UpdateAzureMLCommitmentPlan.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
namespace Microsoft.Azure.Commands.MachineLearning
2121
{
2222
using Common.Authentication.Abstractions;
23+
using ResourceManager.Common.ArgumentCompleters;
2324
using System.Collections.Generic;
2425
using System.Linq;
2526

@@ -28,6 +29,7 @@ namespace Microsoft.Azure.Commands.MachineLearning
2829
public class UpdateAzureMLCommitmentPlan : CommitmentPlansCmdletBase
2930
{
3031
[Parameter(Mandatory = true, HelpMessage = "The name of the resource group for the Azure ML commitment plan.")]
32+
[ResourceGroupCompleter]
3133
[ValidateNotNullOrEmpty]
3234
public string ResourceGroupName { get; set; }
3335

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/WebServices/AddAzureMLWebServiceRegionalProperty.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
using Microsoft.Azure.Management.MachineLearning.WebServices.Util;
2020
using Microsoft.WindowsAzure.Commands.Common;
2121
using Microsoft.Azure.Commands.Common.Authentication.Abstractions;
22+
using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters;
2223

2324
namespace Microsoft.Azure.Commands.MachineLearning.Cmdlets
2425
{
@@ -33,6 +34,7 @@ public class AddAzureMLWebServiceRegionalProperty : WebServicesCmdletBase
3334
Mandatory = true,
3435
ValueFromPipelineByPropertyName = true,
3536
HelpMessage = "The name of the resource group for the Azure ML web service.")]
37+
[ResourceGroupCompleter]
3638
[ValidateNotNullOrEmpty]
3739
public string ResourceGroupName { get; set; }
3840

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/WebServices/GetAzureMLWebService.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
using System.Threading.Tasks;
1919
using Microsoft.Azure.Management.MachineLearning.WebServices.Models;
2020
using Microsoft.Azure.Commands.ResourceManager.Common;
21+
using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters;
2122

2223
namespace Microsoft.Azure.Commands.MachineLearning
2324
{
@@ -28,6 +29,7 @@ public class GetAzureMLWebService : WebServicesCmdletBase
2829
[Parameter(
2930
Mandatory = false,
3031
HelpMessage = "The name of the resource group for the Azure ML web service.")]
32+
[ResourceGroupCompleter]
3133
[ValidateNotNullOrEmpty]
3234
public string ResourceGroupName { get; set; }
3335

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/WebServices/GetAzureMLWebServiceKeys.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
using System.Management.Automation;
1717
using Microsoft.Azure.Commands.MachineLearning.Utilities;
1818
using Microsoft.Azure.Management.MachineLearning.WebServices.Models;
19+
using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters;
1920

2021
namespace Microsoft.Azure.Commands.MachineLearning.Cmdlets
2122
{
@@ -30,6 +31,7 @@ public class GetAzureMLWebServiceKeys : WebServicesCmdletBase
3031
ParameterSetName = GetAzureMLWebServiceKeys.GetKeysByGroupAndName,
3132
Mandatory = true,
3233
HelpMessage = "The name of the resource group for the Azure ML web services.")]
34+
[ResourceGroupCompleter]
3335
[ValidateNotNullOrEmpty]
3436
public string ResourceGroupName { get; set; }
3537

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/WebServices/NewAzureMLWebService.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
using Microsoft.Azure.Management.MachineLearning.WebServices.Util;
2020
using Microsoft.WindowsAzure.Commands.Common;
2121
using Microsoft.Azure.Commands.Common.Authentication.Abstractions;
22+
using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters;
2223

2324
namespace Microsoft.Azure.Commands.MachineLearning.Cmdlets
2425
{
@@ -35,6 +36,7 @@ public class NewAzureMLWebService : WebServicesCmdletBase
3536
[Parameter(
3637
Mandatory = true,
3738
HelpMessage = "The name of the resource group for the Azure ML web service.")]
39+
[ResourceGroupCompleter]
3840
[ValidateNotNullOrEmpty]
3941
public string ResourceGroupName { get; set; }
4042

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/WebServices/RemoveAzureMLWebService.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
using Microsoft.Azure.Management.MachineLearning.WebServices.Models;
1919
using Microsoft.WindowsAzure.Commands.Common;
2020
using Microsoft.Azure.Commands.Common.Authentication.Abstractions;
21+
using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters;
2122

2223
namespace Microsoft.Azure.Commands.MachineLearning
2324
{
@@ -35,6 +36,7 @@ public class RemoveAzureMLWebService : WebServicesCmdletBase
3536
ParameterSetName = RemoveAzureMLWebService.RemoveByNameGroupParameterSet,
3637
Mandatory = true,
3738
HelpMessage = "The name of the resource group for the Azure ML web service.")]
39+
[ResourceGroupCompleter]
3840
[ValidateNotNullOrEmpty]
3941
public string ResourceGroupName { get; set; }
4042

src/ResourceManager/MachineLearning/Commands.MachineLearning/Cmdlets/WebServices/UpdateAzureMLWebService.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
using Microsoft.Azure.Management.MachineLearning.WebServices.Models;
2121
using Microsoft.WindowsAzure.Commands.Common;
2222
using Microsoft.Azure.Commands.Common.Authentication.Abstractions;
23+
using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters;
2324

2425
namespace Microsoft.Azure.Commands.MachineLearning
2526
{
@@ -34,6 +35,7 @@ public class UpdateAzureMLWebService : WebServicesCmdletBase
3435
protected const string UpdateFromObjectParameterSet = "UpdateFromObject";
3536

3637
[Parameter(Mandatory = true, HelpMessage = "The name of the resource group for the Azure ML web service.")]
38+
[ResourceGroupCompleter]
3739
[ValidateNotNullOrEmpty]
3840
public string ResourceGroupName { get; set; }
3941

0 commit comments

Comments
 (0)