Skip to content

Commit a6d061e

Browse files
soeommsJinLei
authored andcommitted
fix help mds and add PSArgumentCompleter
1 parent b6ffaa4 commit a6d061e

13 files changed

+36
-14
lines changed

src/CosmosDB/CosmosDB/CosmosDBAccount/NewAzCosmosDBAccount.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ public class NewAzCosmosDBAccount : AzureCosmosDBCmdletBase
8686
public string ApiKind { get; set; }
8787

8888
[Parameter(Mandatory = false, HelpMessage = Constants.PublicNetworkAccessHelpMessage)]
89-
[ValidateNotNullOrEmpty]
89+
[PSArgumentCompleter("Disabled", "Enabled")]
9090
public string PublicNetworkAccess { get; set; }
9191

9292
[Parameter(Mandatory = false, HelpMessage = Constants.DisableKeyBasedMetadataWriteAccessHelpMessage)]

src/CosmosDB/CosmosDB/CosmosDBAccount/UpdateAzCosmosDBAccount.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ public class UpdateAzCosmosDBAccount : AzureCosmosDBCmdletBase
8585
public bool? DisableKeyBasedMetadataWriteAccess { get; set; }
8686

8787
[Parameter(Mandatory = false, HelpMessage = Constants.PublicNetworkAccessHelpMessage)]
88-
[ValidateNotNullOrEmpty]
88+
[PSArgumentCompleter("Disabled", "Enabled")]
8989
public string PublicNetworkAccess { get; set; }
9090

9191
[Parameter(Mandatory = false, HelpMessage = Constants.AsJobHelpMessage)]

src/CosmosDB/CosmosDB/help/New-AzCosmosDBAccount.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,9 @@ New-AzCosmosDBAccount -ResourceGroupName <String> -Name <String> [-DefaultConsis
1717
[-EnableAutomaticFailover] [-EnableMultipleWriteLocations] [-EnableVirtualNetwork] [-IpRangeFilter <String[]>]
1818
[-Location <String[]>] [-LocationObject <PSLocation[]>] [-MaxStalenessIntervalInSeconds <Int32>]
1919
[-MaxStalenessPrefix <Int32>] [-Tag <Hashtable>] [-VirtualNetworkRule <String[]>]
20-
[-VirtualNetworkRuleObject <PSVirtualNetworkRule[]>] [-PublicNetworkAccess <String>] [-ApiKind <String>]
21-
[-DisableKeyBasedMetadataWriteAccess] [-AsJob] [-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm] [<CommonParameters>]
20+
[-VirtualNetworkRuleObject <PSVirtualNetworkRule[]>] [-ApiKind <String>] [-PublicNetworkAccess <String>]
21+
[-DisableKeyBasedMetadataWriteAccess] [-AsJob] [-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm]
22+
[<CommonParameters>]
2223
```
2324

2425
## DESCRIPTION
@@ -292,8 +293,7 @@ Accept wildcard characters: False
292293
```
293294
294295
### -PublicNetworkAccess
295-
Whether or not public endpoint access is allowed for this server.
296-
Possible values include: 'Enabled', 'Disabled'
296+
Whether or not public endpoint access is allowed for this server. Possible values include: 'Enabled', 'Disabled'
297297
298298
```yaml
299299
Type: String
@@ -305,6 +305,7 @@ Position: Named
305305
Default value: None
306306
Accept pipeline input: False
307307
Accept wildcard characters: False
308+
```
308309
309310
### -ResourceGroupName
310311
Name of resource group.

src/CosmosDB/CosmosDB/help/Update-AzCosmosDBAccount.md

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,9 @@ Update-AzCosmosDBAccount -ResourceGroupName <String> -Name <String> [-DefaultCon
1818
[-EnableAutomaticFailover <Boolean>] [-EnableMultipleWriteLocations <Boolean>]
1919
[-EnableVirtualNetwork <Boolean>] [-IpRangeFilter <String[]>] [-MaxStalenessIntervalInSeconds <Int32>]
2020
[-MaxStalenessPrefix <Int32>] [-Tag <Hashtable>] [-VirtualNetworkRule <String[]>]
21-
[-VirtualNetworkRuleObject <PSVirtualNetworkRule[]>] [-PublicNetworkAccess <String>] [-DisableKeyBasedMetadataWriteAccess <Boolean>]
22-
[-AsJob] [-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm] [<CommonParameters>]
21+
[-VirtualNetworkRuleObject <PSVirtualNetworkRule[]>] [-DisableKeyBasedMetadataWriteAccess <Boolean>]
22+
[-PublicNetworkAccess <String>] [-AsJob] [-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm]
23+
[<CommonParameters>]
2324
```
2425

2526
### ByResourceIdParameterSet
@@ -28,8 +29,9 @@ Update-AzCosmosDBAccount -ResourceId <String> [-DefaultConsistencyLevel <String>
2829
[-EnableAutomaticFailover <Boolean>] [-EnableMultipleWriteLocations <Boolean>]
2930
[-EnableVirtualNetwork <Boolean>] [-IpRangeFilter <String[]>] [-MaxStalenessIntervalInSeconds <Int32>]
3031
[-MaxStalenessPrefix <Int32>] [-Tag <Hashtable>] [-VirtualNetworkRule <String[]>]
31-
[-VirtualNetworkRuleObject <PSVirtualNetworkRule[]>] [-PublicNetworkAccess <String>] [-DisableKeyBasedMetadataWriteAccess <Boolean>]
32-
[-AsJob] [-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm] [<CommonParameters>]
32+
[-VirtualNetworkRuleObject <PSVirtualNetworkRule[]>] [-DisableKeyBasedMetadataWriteAccess <Boolean>]
33+
[-PublicNetworkAccess <String>] [-AsJob] [-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm]
34+
[<CommonParameters>]
3335
```
3436

3537
### ByObjectParameterSet
@@ -38,8 +40,9 @@ Update-AzCosmosDBAccount -InputObject <PSDatabaseAccount> [-DefaultConsistencyLe
3840
[-EnableAutomaticFailover <Boolean>] [-EnableMultipleWriteLocations <Boolean>]
3941
[-EnableVirtualNetwork <Boolean>] [-IpRangeFilter <String[]>] [-MaxStalenessIntervalInSeconds <Int32>]
4042
[-MaxStalenessPrefix <Int32>] [-Tag <Hashtable>] [-VirtualNetworkRule <String[]>]
41-
[-VirtualNetworkRuleObject <PSVirtualNetworkRule[]>] [-PublicNetworkAccess <String>] [-DisableKeyBasedMetadataWriteAccess <Boolean>]
42-
[-AsJob] [-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm] [<CommonParameters>]
43+
[-VirtualNetworkRuleObject <PSVirtualNetworkRule[]>] [-DisableKeyBasedMetadataWriteAccess <Boolean>]
44+
[-PublicNetworkAccess <String>] [-AsJob] [-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm]
45+
[<CommonParameters>]
4346
```
4447

4548
## DESCRIPTION
@@ -280,8 +283,7 @@ Accept wildcard characters: False
280283
```
281284
282285
### -PublicNetworkAccess
283-
Whether or not public endpoint access is allowed for this server.
284-
Possible values include: 'Enabled', 'Disabled'
286+
Whether or not public endpoint access is allowed for this server. Possible values include: 'Enabled', 'Disabled'
285287
286288
```yaml
287289
Type: String
@@ -293,6 +295,7 @@ Position: Named
293295
Default value: None
294296
Accept pipeline input: False
295297
Accept wildcard characters: False
298+
```
296299
297300
### -ResourceGroupName
298301
Name of resource group.

src/CosmosDB/CosmosDB/help/Update-AzCosmosDBCassandraKeyspaceThroughput.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ Update-AzCosmosDBCassandraKeyspaceThroughput [-Name <String>] -Throughput <Int32
3232
[<CommonParameters>]
3333
```
3434

35+
## DESCRIPTION
36+
3537
## EXAMPLES
3638

3739
### Example 1

src/CosmosDB/CosmosDB/help/Update-AzCosmosDBCassandraTableThroughput.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ Update-AzCosmosDBCassandraTableThroughput [-Name <String>] -Throughput <Int32>
3333
[<CommonParameters>]
3434
```
3535

36+
## DESCRIPTION
37+
3638
## EXAMPLES
3739

3840
### Example 1

src/CosmosDB/CosmosDB/help/Update-AzCosmosDBGremlinDatabaseThroughput.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ Update-AzCosmosDBGremlinDatabaseThroughput [-Name <String>] -Throughput <Int32>
3232
[<CommonParameters>]
3333
```
3434

35+
## DESCRIPTION
36+
3537
## EXAMPLES
3638

3739
### Example 1

src/CosmosDB/CosmosDB/help/Update-AzCosmosDBGremlinGraphThroughput.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ Update-AzCosmosDBGremlinGraphThroughput [-Name <String>] -Throughput <Int32>
3333
[<CommonParameters>]
3434
```
3535

36+
## DESCRIPTION
37+
3638
## EXAMPLES
3739

3840
### Example 1

src/CosmosDB/CosmosDB/help/Update-AzCosmosDBMongoDBCollectionThroughput.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ Update-AzCosmosDBMongoDBCollectionThroughput [-Name <String>] -Throughput <Int32
3333
[<CommonParameters>]
3434
```
3535

36+
## DESCRIPTION
37+
3638
## EXAMPLES
3739

3840
### Example 1

src/CosmosDB/CosmosDB/help/Update-AzCosmosDBMongoDBDatabaseThroughput.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ Update-AzCosmosDBMongoDBDatabaseThroughput [-Name <String>] -Throughput <Int32>
3232
[<CommonParameters>]
3333
```
3434

35+
## DESCRIPTION
36+
3537
## EXAMPLES
3638

3739
### Example 1

src/CosmosDB/CosmosDB/help/Update-AzCosmosDBSqlContainerThroughput.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ Update-AzCosmosDBSqlContainerThroughput [-Name <String>] -Throughput <Int32>
3333
[<CommonParameters>]
3434
```
3535

36+
## DESCRIPTION
37+
3638
## EXAMPLES
3739

3840
### Example 1

src/CosmosDB/CosmosDB/help/Update-AzCosmosDBSqlDatabaseThroughput.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@ Update-AzCosmosDBSqlDatabaseThroughput [-Name <String>] -Throughput <Int32>
3131
[<CommonParameters>]
3232
```
3333

34+
## DESCRIPTION
35+
3436
## EXAMPLES
3537

3638
### Example 1

src/CosmosDB/CosmosDB/help/Update-AzCosmosDBTableThroughput.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ Update-AzCosmosDBTableThroughput [-Name <String>] -Throughput <Int32> -InputObje
3030
[-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm] [<CommonParameters>]
3131
```
3232

33+
## DESCRIPTION
34+
3335
## EXAMPLES
3436

3537
### Example 1

0 commit comments

Comments
 (0)