Skip to content

Commit

Permalink
.NET SDK Resource Provider:'Compute'
Browse files Browse the repository at this point in the history
REST Spec PR 'Azure/azure-rest-api-specs#5560'
REST Spec PR Author 'vamuzumd'
REST Spec PR Last commit
  • Loading branch information
adxsdknet committed Apr 8, 2019
1 parent 7459d4f commit c2cd9d5
Show file tree
Hide file tree
Showing 11 changed files with 223 additions and 20 deletions.
2 changes: 1 addition & 1 deletion src/SDKs/Compute/AzSdk.RP.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!--This file and it's contents are updated at build time moving or editing might result in build failure. Take due deligence while editing this file-->
<PropertyGroup>
<AzureApiTag>Compute_2019-03-01;Compute_2018-09-30;Compute_2018-06-01;Compute_2017-09-01;ContainerService_2017-01-31;</AzureApiTag>
<AzureApiTag>Compute_2019-03-01;Compute_2018-09-30;Compute_2017-09-01;ContainerService_2017-01-31;</AzureApiTag>
<PackageTags>$(PackageTags);$(CommonTags);$(AzureApiTag);</PackageTags>
</PropertyGroup>
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ internal GalleriesOperations(ComputeManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "galleryName");
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down Expand Up @@ -330,7 +330,7 @@ internal GalleriesOperations(ComputeManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "resourceGroupName");
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down Expand Up @@ -508,7 +508,7 @@ internal GalleriesOperations(ComputeManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId");
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down Expand Up @@ -711,7 +711,7 @@ internal GalleriesOperations(ComputeManagementClient client)
{
gallery.Validate();
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down Expand Up @@ -945,7 +945,7 @@ internal GalleriesOperations(ComputeManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "galleryName");
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ internal GalleryImageVersionsOperations(ComputeManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "galleryImageVersionName");
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down Expand Up @@ -389,7 +389,7 @@ internal GalleryImageVersionsOperations(ComputeManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "galleryImageName");
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down Expand Up @@ -615,7 +615,7 @@ internal GalleryImageVersionsOperations(ComputeManagementClient client)
{
galleryImageVersion.Validate();
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down Expand Up @@ -868,7 +868,7 @@ internal GalleryImageVersionsOperations(ComputeManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "galleryImageVersionName");
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ internal GalleryImagesOperations(ComputeManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "galleryImageName");
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down Expand Up @@ -356,7 +356,7 @@ internal GalleryImagesOperations(ComputeManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "galleryName");
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down Expand Up @@ -571,7 +571,7 @@ internal GalleryImagesOperations(ComputeManagementClient client)
{
galleryImage.Validate();
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down Expand Up @@ -815,7 +815,7 @@ internal GalleryImagesOperations(ComputeManagementClient client)
{
throw new ValidationException(ValidationRules.CannotBeNull, "galleryImageName");
}
string apiVersion = "2018-06-01";
string apiVersion = "2019-03-01";
// Tracing
bool _shouldTrace = ServiceClientTracing.IsEnabled;
string _invocationId = null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,17 @@ public GalleryImageVersionPublishingProfile()
/// <param name="endOfLifeDate">The end of life date of the gallery
/// Image Version. This property can be used for decommissioning
/// purposes. This property is updatable.</param>
public GalleryImageVersionPublishingProfile(GalleryArtifactSource source, IList<TargetRegion> targetRegions = default(IList<TargetRegion>), int? replicaCount = default(int?), bool? excludeFromLatest = default(bool?), System.DateTime? publishedDate = default(System.DateTime?), System.DateTime? endOfLifeDate = default(System.DateTime?))
/// <param name="storageAccountType">Specifies the storage account type
/// to be used to store the image. This property is not updatable.
/// Possible values include: 'Standard_LRS', 'Standard_ZRS'</param>
public GalleryImageVersionPublishingProfile(GalleryArtifactSource source, IList<TargetRegion> targetRegions = default(IList<TargetRegion>), int? replicaCount = default(int?), bool? excludeFromLatest = default(bool?), System.DateTime? publishedDate = default(System.DateTime?), System.DateTime? endOfLifeDate = default(System.DateTime?), string storageAccountType = default(string))
: base(source, targetRegions)
{
ReplicaCount = replicaCount;
ExcludeFromLatest = excludeFromLatest;
PublishedDate = publishedDate;
EndOfLifeDate = endOfLifeDate;
StorageAccountType = storageAccountType;
CustomInit();
}

Expand Down Expand Up @@ -94,6 +98,14 @@ public GalleryImageVersionPublishingProfile()
[JsonProperty(PropertyName = "endOfLifeDate")]
public System.DateTime? EndOfLifeDate { get; set; }

/// <summary>
/// Gets or sets specifies the storage account type to be used to store
/// the image. This property is not updatable. Possible values include:
/// 'Standard_LRS', 'Standard_ZRS'
/// </summary>
[JsonProperty(PropertyName = "storageAccountType")]
public string StorageAccountType { get; set; }

/// <summary>
/// Validate the object.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
// <auto-generated>
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// regenerated.
// </auto-generated>

namespace Microsoft.Azure.Management.Compute.Models
{

/// <summary>
/// Defines values for StorageAccountType.
/// </summary>
public static class StorageAccountType
{
public const string StandardLRS = "Standard_LRS";
public const string StandardZRS = "Standard_ZRS";
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,14 @@ public TargetRegion()
/// <param name="regionalReplicaCount">The number of replicas of the
/// Image Version to be created per region. This property is
/// updatable.</param>
public TargetRegion(string name, int? regionalReplicaCount = default(int?))
/// <param name="storageAccountType">Specifies the storage account type
/// to be used to store the image. This property is not updatable.
/// Possible values include: 'Standard_LRS', 'Standard_ZRS'</param>
public TargetRegion(string name, int? regionalReplicaCount = default(int?), string storageAccountType = default(string))
{
Name = name;
RegionalReplicaCount = regionalReplicaCount;
StorageAccountType = storageAccountType;
CustomInit();
}

Expand All @@ -59,6 +63,14 @@ public TargetRegion()
[JsonProperty(PropertyName = "regionalReplicaCount")]
public int? RegionalReplicaCount { get; set; }

/// <summary>
/// Gets or sets specifies the storage account type to be used to store
/// the image. This property is not updatable. Possible values include:
/// 'Standard_LRS', 'Standard_ZRS'
/// </summary>
[JsonProperty(PropertyName = "storageAccountType")]
public string StorageAccountType { get; set; }

/// <summary>
/// Validate the object.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@ public VirtualMachineScaleSetVM()
/// the virtual machine.</param>
/// <param name="networkProfile">Specifies the network interfaces of
/// the virtual machine.</param>
/// <param name="networkProfileConfiguration">Specifies the network
/// profile configuration of the virtual machine.</param>
/// <param name="diagnosticsProfile">Specifies the boot diagnostic
/// settings state. &lt;br&gt;&lt;br&gt;Minimum api-version:
/// 2015-06-15.</param>
Expand Down Expand Up @@ -88,6 +90,11 @@ public VirtualMachineScaleSetVM()
/// [Azure Hybrid Use Benefit for Windows
/// Server](https://docs.microsoft.com/azure/virtual-machines/virtual-machines-windows-hybrid-use-benefit-licensing?toc=%2fazure%2fvirtual-machines%2fwindows%2ftoc.json)
/// &lt;br&gt;&lt;br&gt; Minimum api-version: 2015-06-15</param>
/// <param name="modelDefinitionApplied">Specifies whether the model
/// applied to the virtual machine is the model of the virtual machine
/// scale set or the customized model for the virtual machine.</param>
/// <param name="protectionPolicy">Specifies the protection policy of
/// the virtual machine.</param>
/// <param name="plan">Specifies information about the marketplace
/// image used to create the virtual machine. This element is only used
/// for marketplace images. Before you can use a marketplace image from
Expand All @@ -98,7 +105,7 @@ public VirtualMachineScaleSetVM()
/// <param name="resources">The virtual machine child extension
/// resources.</param>
/// <param name="zones">The virtual machine zones.</param>
public VirtualMachineScaleSetVM(string location, string id = default(string), string name = default(string), string type = default(string), IDictionary<string, string> tags = default(IDictionary<string, string>), string instanceId = default(string), Sku sku = default(Sku), bool? latestModelApplied = default(bool?), string vmId = default(string), VirtualMachineScaleSetVMInstanceView instanceView = default(VirtualMachineScaleSetVMInstanceView), HardwareProfile hardwareProfile = default(HardwareProfile), StorageProfile storageProfile = default(StorageProfile), AdditionalCapabilities additionalCapabilities = default(AdditionalCapabilities), OSProfile osProfile = default(OSProfile), NetworkProfile networkProfile = default(NetworkProfile), DiagnosticsProfile diagnosticsProfile = default(DiagnosticsProfile), SubResource availabilitySet = default(SubResource), string provisioningState = default(string), string licenseType = default(string), Plan plan = default(Plan), IList<VirtualMachineExtension> resources = default(IList<VirtualMachineExtension>), IList<string> zones = default(IList<string>))
public VirtualMachineScaleSetVM(string location, string id = default(string), string name = default(string), string type = default(string), IDictionary<string, string> tags = default(IDictionary<string, string>), string instanceId = default(string), Sku sku = default(Sku), bool? latestModelApplied = default(bool?), string vmId = default(string), VirtualMachineScaleSetVMInstanceView instanceView = default(VirtualMachineScaleSetVMInstanceView), HardwareProfile hardwareProfile = default(HardwareProfile), StorageProfile storageProfile = default(StorageProfile), AdditionalCapabilities additionalCapabilities = default(AdditionalCapabilities), OSProfile osProfile = default(OSProfile), NetworkProfile networkProfile = default(NetworkProfile), VirtualMachineScaleSetVMNetworkProfileConfiguration networkProfileConfiguration = default(VirtualMachineScaleSetVMNetworkProfileConfiguration), DiagnosticsProfile diagnosticsProfile = default(DiagnosticsProfile), SubResource availabilitySet = default(SubResource), string provisioningState = default(string), string licenseType = default(string), string modelDefinitionApplied = default(string), VirtualMachineScaleSetVMProtectionPolicy protectionPolicy = default(VirtualMachineScaleSetVMProtectionPolicy), Plan plan = default(Plan), IList<VirtualMachineExtension> resources = default(IList<VirtualMachineExtension>), IList<string> zones = default(IList<string>))
: base(location, id, name, type, tags)
{
InstanceId = instanceId;
Expand All @@ -111,10 +118,13 @@ public VirtualMachineScaleSetVM()
AdditionalCapabilities = additionalCapabilities;
OsProfile = osProfile;
NetworkProfile = networkProfile;
NetworkProfileConfiguration = networkProfileConfiguration;
DiagnosticsProfile = diagnosticsProfile;
AvailabilitySet = availabilitySet;
ProvisioningState = provisioningState;
LicenseType = licenseType;
ModelDefinitionApplied = modelDefinitionApplied;
ProtectionPolicy = protectionPolicy;
Plan = plan;
Resources = resources;
Zones = zones;
Expand Down Expand Up @@ -194,6 +204,13 @@ public VirtualMachineScaleSetVM()
[JsonProperty(PropertyName = "properties.networkProfile")]
public NetworkProfile NetworkProfile { get; set; }

/// <summary>
/// Gets or sets specifies the network profile configuration of the
/// virtual machine.
/// </summary>
[JsonProperty(PropertyName = "properties.networkProfileConfiguration")]
public VirtualMachineScaleSetVMNetworkProfileConfiguration NetworkProfileConfiguration { get; set; }

/// <summary>
/// Gets or sets specifies the boot diagnostic settings state.
/// &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Minimum api-version:
Expand Down Expand Up @@ -244,6 +261,21 @@ public VirtualMachineScaleSetVM()
[JsonProperty(PropertyName = "properties.licenseType")]
public string LicenseType { get; set; }

/// <summary>
/// Gets specifies whether the model applied to the virtual machine is
/// the model of the virtual machine scale set or the customized model
/// for the virtual machine.
/// </summary>
[JsonProperty(PropertyName = "properties.modelDefinitionApplied")]
public string ModelDefinitionApplied { get; private set; }

/// <summary>
/// Gets or sets specifies the protection policy of the virtual
/// machine.
/// </summary>
[JsonProperty(PropertyName = "properties.protectionPolicy")]
public VirtualMachineScaleSetVMProtectionPolicy ProtectionPolicy { get; set; }

/// <summary>
/// Gets or sets specifies information about the marketplace image used
/// to create the virtual machine. This element is only used for
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
// <auto-generated>
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// regenerated.
// </auto-generated>

namespace Microsoft.Azure.Management.Compute.Models
{
using Newtonsoft.Json;
using System.Collections;
using System.Collections.Generic;
using System.Linq;

/// <summary>
/// Describes a virtual machine scale set VM network profile.
/// </summary>
public partial class VirtualMachineScaleSetVMNetworkProfileConfiguration
{
/// <summary>
/// Initializes a new instance of the
/// VirtualMachineScaleSetVMNetworkProfileConfiguration class.
/// </summary>
public VirtualMachineScaleSetVMNetworkProfileConfiguration()
{
CustomInit();
}

/// <summary>
/// Initializes a new instance of the
/// VirtualMachineScaleSetVMNetworkProfileConfiguration class.
/// </summary>
/// <param name="networkInterfaceConfigurations">The list of network
/// configurations.</param>
public VirtualMachineScaleSetVMNetworkProfileConfiguration(IList<VirtualMachineScaleSetNetworkConfiguration> networkInterfaceConfigurations = default(IList<VirtualMachineScaleSetNetworkConfiguration>))
{
NetworkInterfaceConfigurations = networkInterfaceConfigurations;
CustomInit();
}

/// <summary>
/// An initialization method that performs custom operations like setting defaults
/// </summary>
partial void CustomInit();

/// <summary>
/// Gets or sets the list of network configurations.
/// </summary>
[JsonProperty(PropertyName = "networkInterfaceConfigurations")]
public IList<VirtualMachineScaleSetNetworkConfiguration> NetworkInterfaceConfigurations { get; set; }

}
}
Loading

0 comments on commit c2cd9d5

Please sign in to comment.