Skip to content

Commit aacdcf2

Browse files
committed
Storage: more custom
1 parent 9b7873a commit aacdcf2

19 files changed

+1052
-114
lines changed
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
namespace Microsoft.Azure.PowerShell.Cmdlets.Storage.Cmdlets
2+
{
3+
public partial class NewAzStorageAccount_CreateExpanded
4+
{
5+
// Workaround for the lack of a parameter being created for an object that has only a required constant.
6+
// add a parameter that creates the otherwise empty object.
7+
[System.Management.Automation.Parameter(Mandatory = false, HelpMessage = "Specify IdentityType as 'SystemAssigned'")]
8+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category(Microsoft.Azure.PowerShell.Cmdlets.Storage.ParameterCategory.Body)]
9+
public System.Management.Automation.SwitchParameter AssignIdentity { set {
10+
// if this switch is set, just use the internal setter for the Identity property
11+
// and set a new Identity object, which has the Type as a constant.
12+
((Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20190401.IStorageAccountCreateParametersInternal)this.ParametersBody).Identity = new Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.Identity();
13+
}}
14+
}
15+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
namespace Microsoft.Azure.PowerShell.Cmdlets.Storage.Cmdlets
2+
{
3+
public partial class NewAzStorageAccount_CreateExpanded1
4+
{
5+
// Workaround for the lack of a parameter being created for an object that has only a required constant.
6+
// add a parameter that creates the otherwise empty object.
7+
[System.Management.Automation.Parameter(Mandatory = false, HelpMessage = "Specify IdentityType as 'SystemAssigned'")]
8+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category(Microsoft.Azure.PowerShell.Cmdlets.Storage.ParameterCategory.Body)]
9+
public System.Management.Automation.SwitchParameter AssignIdentity { set {
10+
// if this switch is set, just use the internal setter for the Identity property
11+
// and set a new Identity object, which has the Type as a constant.
12+
((Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.IStorageAccountCreateParametersInternal)this.ParametersBody).Identity = new Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.Identity();
13+
}}
14+
}
15+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
namespace Microsoft.Azure.PowerShell.Cmdlets.Storage.Cmdlets
2+
{
3+
public partial class NewAzStorageAccount_CreateViaIdentityExpanded
4+
{
5+
// Workaround for the lack of a parameter being created for an object that has only a required constant.
6+
// add a parameter that creates the otherwise empty object.
7+
[System.Management.Automation.Parameter(Mandatory = false, HelpMessage = "Specify IdentityType as 'SystemAssigned'")]
8+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category(Microsoft.Azure.PowerShell.Cmdlets.Storage.ParameterCategory.Body)]
9+
public System.Management.Automation.SwitchParameter AssignIdentity { set {
10+
// if this switch is set, just use the internal setter for the Identity property
11+
// and set a new Identity object, which has the Type as a constant.
12+
((Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20190401.IStorageAccountCreateParametersInternal)this.ParametersBody).Identity = new Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.Identity();
13+
}}
14+
}
15+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
namespace Microsoft.Azure.PowerShell.Cmdlets.Storage.Cmdlets
2+
{
3+
public partial class NewAzStorageAccount_CreateViaIdentityExpanded1
4+
{
5+
// Workaround for the lack of a parameter being created for an object that has only a required constant.
6+
// add a parameter that creates the otherwise empty object.
7+
[System.Management.Automation.Parameter(Mandatory = false, HelpMessage = "Specify IdentityType as 'SystemAssigned'")]
8+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category(Microsoft.Azure.PowerShell.Cmdlets.Storage.ParameterCategory.Body)]
9+
public System.Management.Automation.SwitchParameter AssignIdentity { set {
10+
// if this switch is set, just use the internal setter for the Identity property
11+
// and set a new Identity object, which has the Type as a constant.
12+
((Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.IStorageAccountCreateParametersInternal)this.ParametersBody).Identity = new Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.Identity();
13+
}}
14+
}
15+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
namespace Microsoft.Azure.PowerShell.Cmdlets.Storage.Cmdlets
2+
{
3+
public partial class UpdateAzStorageAccount_UpdateExpanded
4+
{
5+
// Workaround for the lack of a parameter being created for an object that has only a required constant.
6+
// add a parameter that creates the otherwise empty object.
7+
[System.Management.Automation.Parameter(Mandatory = false, HelpMessage = "Specify IdentityType as 'SystemAssigned'")]
8+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category(Microsoft.Azure.PowerShell.Cmdlets.Storage.ParameterCategory.Body)]
9+
public System.Management.Automation.SwitchParameter AssignIdentity { set {
10+
// if this switch is set, just use the internal setter for the Identity property
11+
// and set a new Identity object, which has the Type as a constant.
12+
((Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.IStorageAccountUpdateParametersInternal)this.ParametersBody).Identity = new Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.Identity();
13+
}}
14+
}
15+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
namespace Microsoft.Azure.PowerShell.Cmdlets.Storage.Cmdlets
2+
{
3+
public partial class UpdateAzStorageAccount_UpdateExpanded1
4+
{
5+
// Workaround for the lack of a parameter being created for an object that has only a required constant.
6+
// add a parameter that creates the otherwise empty object.
7+
[System.Management.Automation.Parameter(Mandatory = false, HelpMessage = "Specify IdentityType as 'SystemAssigned'")]
8+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category(Microsoft.Azure.PowerShell.Cmdlets.Storage.ParameterCategory.Body)]
9+
public System.Management.Automation.SwitchParameter AssignIdentity { set {
10+
// if this switch is set, just use the internal setter for the Identity property
11+
// and set a new Identity object, which has the Type as a constant.
12+
((Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20190401.IStorageAccountUpdateParametersInternal)this.ParametersBody).Identity = new Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.Identity();
13+
}}
14+
}
15+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
namespace Microsoft.Azure.PowerShell.Cmdlets.Storage.Cmdlets
2+
{
3+
public partial class UpdateAzStorageAccount_UpdateViaIdentityExpanded
4+
{
5+
// Workaround for the lack of a parameter being created for an object that has only a required constant.
6+
// add a parameter that creates the otherwise empty object.
7+
[System.Management.Automation.Parameter(Mandatory = false, HelpMessage = "Specify IdentityType as 'SystemAssigned'")]
8+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category(Microsoft.Azure.PowerShell.Cmdlets.Storage.ParameterCategory.Body)]
9+
public System.Management.Automation.SwitchParameter AssignIdentity { set {
10+
// if this switch is set, just use the internal setter for the Identity property
11+
// and set a new Identity object, which has the Type as a constant.
12+
((Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.IStorageAccountUpdateParametersInternal)this.ParametersBody).Identity = new Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.Identity();
13+
}}
14+
}
15+
}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
namespace Microsoft.Azure.PowerShell.Cmdlets.Storage.Cmdlets
2+
{
3+
public partial class UpdateAzStorageAccount_UpdateViaIdentityExpanded1
4+
{
5+
// Workaround for the lack of a parameter being created for an object that has only a required constant.
6+
// add a parameter that creates the otherwise empty object.
7+
[System.Management.Automation.Parameter(Mandatory = false, HelpMessage = "Specify IdentityType as 'SystemAssigned'")]
8+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category(Microsoft.Azure.PowerShell.Cmdlets.Storage.ParameterCategory.Body)]
9+
public System.Management.Automation.SwitchParameter AssignIdentity { set {
10+
// if this switch is set, just use the internal setter for the Identity property
11+
// and set a new Identity object, which has the Type as a constant.
12+
((Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20190401.IStorageAccountUpdateParametersInternal)this.ParametersBody).Identity = new Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.Identity();
13+
}}
14+
}
15+
}
Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
function Get-AzStorageAccount_GetByName {
2+
[OutputType('Microsoft.Azure.PowerShell.Cmdlets.Storage.Models.Api20171001.IStorageAccount')]
3+
[CmdletBinding(PositionalBinding=$false)]
4+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Profile('hybrid-2019-03-01')]
5+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Description('Lists all the storage accounts available under the subscription. Note that storage keys are not returned; use the ListKeys operation for this.')]
6+
param(
7+
[Parameter(Mandatory, HelpMessage='Gets subscription credentials which uniquely identify the Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.')]
8+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category('Path')]
9+
[System.String[]]
10+
# Gets subscription credentials which uniquely identify the Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
11+
${SubscriptionId},
12+
13+
[Parameter(Mandatory, HelpMessage='The name of the resource group within the user''s subscription. The name is case insensitive.')]
14+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category('Path')]
15+
[System.String]
16+
# The name of the resource group within the user's subscription. The name is case insensitive.
17+
${ResourceGroupName},
18+
19+
[Parameter(Mandatory, HelpMessage='The name of the storage account.')]
20+
[System.String]
21+
${Name},
22+
23+
[Parameter(HelpMessage='The credentials, account, tenant, and subscription used for communication with Azure.')]
24+
[Alias('AzureRMContext', 'AzureCredential')]
25+
[ValidateNotNull()]
26+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category('Azure')]
27+
[System.Management.Automation.PSObject]
28+
# The credentials, account, tenant, and subscription used for communication with Azure.
29+
${DefaultProfile},
30+
31+
[Parameter(DontShow, HelpMessage='Wait for .NET debugger to attach')]
32+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category('Runtime')]
33+
[System.Management.Automation.SwitchParameter]
34+
# Wait for .NET debugger to attach
35+
${Break},
36+
37+
[Parameter(DontShow, HelpMessage='SendAsync Pipeline Steps to be appended to the front of the pipeline')]
38+
[ValidateNotNull()]
39+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category('Runtime')]
40+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Runtime.SendAsyncStep[]]
41+
# SendAsync Pipeline Steps to be appended to the front of the pipeline
42+
${HttpPipelineAppend},
43+
44+
[Parameter(DontShow, HelpMessage='SendAsync Pipeline Steps to be prepended to the front of the pipeline')]
45+
[ValidateNotNull()]
46+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category('Runtime')]
47+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Runtime.SendAsyncStep[]]
48+
# SendAsync Pipeline Steps to be prepended to the front of the pipeline
49+
${HttpPipelinePrepend},
50+
51+
[Parameter(DontShow, HelpMessage='The URI for the proxy server to use')]
52+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category('Runtime')]
53+
[System.Uri]
54+
# The URI for the proxy server to use
55+
${Proxy},
56+
57+
[Parameter(DontShow, HelpMessage='Credentials for a proxy server to use for the remote call')]
58+
[ValidateNotNull()]
59+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category('Runtime')]
60+
[System.Management.Automation.PSCredential]
61+
# Credentials for a proxy server to use for the remote call
62+
${ProxyCredential},
63+
64+
[Parameter(DontShow, HelpMessage='Use the default credentials for the proxy')]
65+
[Microsoft.Azure.PowerShell.Cmdlets.Storage.Category('Runtime')]
66+
[System.Management.Automation.SwitchParameter]
67+
# Use the default credentials for the proxy
68+
${ProxyUseDefaultCredentials}
69+
)
70+
71+
process {
72+
Az.Storage.internal\Get-AzStorageAccountProperty @PSBoundParameters
73+
}
74+
}
75+

0 commit comments

Comments
 (0)