@@ -34,10 +34,9 @@ public class GetAzureProviderOperationCommand : ResourcesBaseCmdlet
34
34
/// <summary>
35
35
/// Gets or sets the provider namespace
36
36
/// </summary>
37
- [ Alias ( "OperationSearchString" ) ]
38
37
[ Parameter ( Position = 0 , Mandatory = true , ValueFromPipelineByPropertyName = false , ValueFromPipeline = true , HelpMessage = "The action string." ) ]
39
38
[ ValidateNotNullOrEmpty ]
40
- public string Name { get ; set ; }
39
+ public string OperationSearchString { get ; set ; }
41
40
42
41
/// <summary>
43
42
/// Executes the cmdlet
@@ -46,19 +45,19 @@ public override void ExecuteCmdlet()
46
45
{
47
46
WriteWarning ( "The output object type of this cmdlet will be modified in a future release." ) ;
48
47
// remove leading and trailing whitespaces
49
- this . Name = this . Name . Trim ( ) ;
48
+ this . OperationSearchString = this . OperationSearchString . Trim ( ) ;
50
49
51
- ValidateActionSearchString ( this . Name ) ;
50
+ ValidateActionSearchString ( this . OperationSearchString ) ;
52
51
53
52
List < PSResourceProviderOperation > operationsToDisplay ;
54
53
55
- if ( this . Name . Contains ( WildCardCharacter ) )
54
+ if ( this . OperationSearchString . Contains ( WildCardCharacter ) )
56
55
{
57
- operationsToDisplay = this . ProcessProviderOperationsWithWildCard ( Name ) ;
56
+ operationsToDisplay = this . ProcessProviderOperationsWithWildCard ( OperationSearchString ) ;
58
57
}
59
58
else
60
59
{
61
- operationsToDisplay = this . ProcessProviderOperationsWithoutWildCard ( Name ) ;
60
+ operationsToDisplay = this . ProcessProviderOperationsWithoutWildCard ( OperationSearchString ) ;
62
61
}
63
62
64
63
this . WriteObject ( operationsToDisplay , enumerateCollection : true ) ;
@@ -92,7 +91,7 @@ private List<PSResourceProviderOperation> ProcessProviderOperationsWithWildCard(
92
91
WildcardPattern wildcard = new WildcardPattern ( actionSearchString , WildcardOptions . IgnoreCase | WildcardOptions . Compiled ) ;
93
92
94
93
List < ProviderOperationsMetadata > providers = new List < ProviderOperationsMetadata > ( ) ;
95
- string provider = this . Name . Split ( Separator ) . First ( ) ;
94
+ string provider = this . OperationSearchString . Split ( Separator ) . First ( ) ;
96
95
if ( provider . Equals ( WildCardCharacter ) )
97
96
{
98
97
// 'Get-AzureRmProviderOperation *' or 'Get-AzureRmProviderOperation */virtualmachines/*'
0 commit comments