diff --git a/sdk/netapp/arm-netapp/package.json b/sdk/netapp/arm-netapp/package.json index 2895a20d582a..e2828a48ec8e 100644 --- a/sdk/netapp/arm-netapp/package.json +++ b/sdk/netapp/arm-netapp/package.json @@ -27,7 +27,7 @@ "rollup-plugin-sourcemaps": "^0.4.2", "uglify-js": "^3.6.0" }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/feature/v4/sdk/netapp/arm-netapp", + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/netapp/arm-netapp", "repository": { "type": "git", "url": "https://github.com/Azure/azure-sdk-for-js.git" diff --git a/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClient.ts b/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClient.ts index 2eac024bfb72..1ff5d6d4ca30 100644 --- a/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClient.ts +++ b/sdk/netapp/arm-netapp/src/azureNetAppFilesManagementClient.ts @@ -19,6 +19,7 @@ class AzureNetAppFilesManagementClient extends AzureNetAppFilesManagementClientC // Operation groups operations: operations.Operations; netAppResource: operations.NetAppResource; + netAppResourceQuotaLimits: operations.NetAppResourceQuotaLimits; accounts: operations.Accounts; pools: operations.Pools; volumes: operations.Volumes; @@ -45,6 +46,7 @@ class AzureNetAppFilesManagementClient extends AzureNetAppFilesManagementClientC super(credentials, subscriptionId, options); this.operations = new operations.Operations(this); this.netAppResource = new operations.NetAppResource(this); + this.netAppResourceQuotaLimits = new operations.NetAppResourceQuotaLimits(this); this.accounts = new operations.Accounts(this); this.pools = new operations.Pools(this); this.volumes = new operations.Volumes(this); diff --git a/sdk/netapp/arm-netapp/src/models/accountBackupsMappers.ts b/sdk/netapp/arm-netapp/src/models/accountBackupsMappers.ts index de742c81ab8d..580151675a70 100644 --- a/sdk/netapp/arm-netapp/src/models/accountBackupsMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/accountBackupsMappers.ts @@ -9,6 +9,7 @@ export { AccountEncryption, ActiveDirectory, + AzureEntityResource, Backup, BackupPatch, BackupPolicy, @@ -26,10 +27,14 @@ export { MountTargetProperties, NetAppAccount, NetAppAccountPatch, + ProxyResource, ReplicationObject, + Resource, Snapshot, SnapshotPolicy, + SubscriptionQuotaItem, SystemData, + TrackedResource, Vault, Volume, VolumeBackupProperties, diff --git a/sdk/netapp/arm-netapp/src/models/accountsMappers.ts b/sdk/netapp/arm-netapp/src/models/accountsMappers.ts index ecf21f05abbf..2dbc04f2e7ac 100644 --- a/sdk/netapp/arm-netapp/src/models/accountsMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/accountsMappers.ts @@ -9,6 +9,7 @@ export { AccountEncryption, ActiveDirectory, + AzureEntityResource, Backup, BackupPatch, BackupPolicy, @@ -26,10 +27,14 @@ export { NetAppAccount, NetAppAccountList, NetAppAccountPatch, + ProxyResource, ReplicationObject, + Resource, Snapshot, SnapshotPolicy, + SubscriptionQuotaItem, SystemData, + TrackedResource, Vault, Volume, VolumeBackupProperties, diff --git a/sdk/netapp/arm-netapp/src/models/backupPoliciesMappers.ts b/sdk/netapp/arm-netapp/src/models/backupPoliciesMappers.ts index 7d1c1a293c6e..673a1e64d8d9 100644 --- a/sdk/netapp/arm-netapp/src/models/backupPoliciesMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/backupPoliciesMappers.ts @@ -9,6 +9,7 @@ export { AccountEncryption, ActiveDirectory, + AzureEntityResource, Backup, BackupPatch, BackupPoliciesList, @@ -26,10 +27,14 @@ export { MountTargetProperties, NetAppAccount, NetAppAccountPatch, + ProxyResource, ReplicationObject, + Resource, Snapshot, SnapshotPolicy, + SubscriptionQuotaItem, SystemData, + TrackedResource, Vault, Volume, VolumeBackupProperties, diff --git a/sdk/netapp/arm-netapp/src/models/backupsMappers.ts b/sdk/netapp/arm-netapp/src/models/backupsMappers.ts index 2f48ce40762e..427ac245a686 100644 --- a/sdk/netapp/arm-netapp/src/models/backupsMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/backupsMappers.ts @@ -9,6 +9,7 @@ export { AccountEncryption, ActiveDirectory, + AzureEntityResource, Backup, BackupPatch, BackupPolicy, @@ -27,11 +28,15 @@ export { MountTargetProperties, NetAppAccount, NetAppAccountPatch, + ProxyResource, ReplicationObject, + Resource, RestoreStatus, Snapshot, SnapshotPolicy, + SubscriptionQuotaItem, SystemData, + TrackedResource, Vault, Volume, VolumeBackupProperties, diff --git a/sdk/netapp/arm-netapp/src/models/index.ts b/sdk/netapp/arm-netapp/src/models/index.ts index f0c53ec90e11..0a594d0abef0 100644 --- a/sdk/netapp/arm-netapp/src/models/index.ts +++ b/sdk/netapp/arm-netapp/src/models/index.ts @@ -79,6 +79,10 @@ export interface MetricSpecification { * The internal metric name. */ internalMetricName?: string; + /** + * Whether or not the service is using regional MDM accounts. + */ + enableRegionalMdmAccount?: boolean; /** * The source MDM account. */ @@ -107,6 +111,18 @@ export interface MetricSpecification { * Account Resource Id. */ resourceIdDimensionNameOverride?: string; + /** + * Whether the metric is internal. + */ + isInternal?: boolean; +} + +/** + * Log Definition of a single resource metric. + */ +export interface LogSpecification { + name?: string; + displayName?: string; } /** @@ -117,6 +133,7 @@ export interface ServiceSpecification { * Metric specifications of operation. */ metricSpecifications?: MetricSpecification[]; + logSpecifications?: LogSpecification[]; } /** @@ -222,6 +239,96 @@ export interface QuotaAvailabilityRequest { resourceGroup: string; } +/** + * Metadata pertaining to creation and last modification of the resource. + */ +export interface SystemData { + /** + * The identity that created the resource. + */ + createdBy?: string; + /** + * The type of identity that created the resource. Possible values include: 'User', + * 'Application', 'ManagedIdentity', 'Key' + */ + createdByType?: CreatedByType; + /** + * The timestamp of resource creation (UTC). + */ + createdAt?: Date; + /** + * The identity that last modified the resource. + */ + lastModifiedBy?: string; + /** + * The type of identity that last modified the resource. Possible values include: 'User', + * 'Application', 'ManagedIdentity', 'Key' + */ + lastModifiedByType?: CreatedByType; + /** + * The timestamp of resource last modification (UTC) + */ + lastModifiedAt?: Date; +} + +/** + * Common fields that are returned in the response for all Azure Resource Manager resources + * @summary Resource + */ +export interface Resource extends BaseResource { + /** + * Fully qualified resource ID for the resource. Ex - + * /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * The name of the resource + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or + * "Microsoft.Storage/storageAccounts" + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; +} + +/** + * The resource model definition for a Azure Resource Manager proxy resource. It will not have tags + * and a location + * @summary Proxy Resource + */ +export interface ProxyResource extends Resource { +} + +/** + * Information regarding Subscription Quota Item. + */ +export interface SubscriptionQuotaItem extends ProxyResource { + /** + * Quota Item name + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly subscriptionQuotaItemName?: string; + /** + * The current quota value. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly current?: number; + /** + * The default quota value. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly default?: number; + /** + * The system meta data relating to this resource. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly systemData?: SystemData; +} + /** * Active Directory */ @@ -331,38 +438,6 @@ export interface AccountEncryption { keySource?: string; } -/** - * Metadata pertaining to creation and last modification of the resource. - */ -export interface SystemData { - /** - * The identity that created the resource. - */ - createdBy?: string; - /** - * The type of identity that created the resource. Possible values include: 'User', - * 'Application', 'ManagedIdentity', 'Key' - */ - createdByType?: CreatedByType; - /** - * The timestamp of resource creation (UTC). - */ - createdAt?: Date; - /** - * The identity that last modified the resource. - */ - lastModifiedBy?: string; - /** - * The type of identity that last modified the resource. Possible values include: 'User', - * 'Application', 'ManagedIdentity', 'Key' - */ - lastModifiedByType?: CreatedByType; - /** - * The timestamp of resource last modification (UTC) - */ - lastModifiedAt?: Date; -} - /** * NetApp account resource */ @@ -724,7 +799,7 @@ export interface ReplicationObject { /** * Schedule. Possible values include: '_10minutely', 'hourly', 'daily' */ - replicationSchedule: ReplicationSchedule; + replicationSchedule?: ReplicationSchedule; /** * The resource ID of the remote volume. */ @@ -848,13 +923,31 @@ export interface Volume extends BaseResource { * Microsoft.NetApp/volumes */ subnetId: string; + /** + * Network features. Basic network, or Standard features available to the volume. Possible values + * include: 'Basic', 'Standard'. Default value: 'Basic'. + */ + networkFeatures?: NetworkFeatures; + /** + * Network Sibling Set ID. Network Sibling Set ID for the the group of volumes sharing networking + * resources. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly networkSiblingSetId?: string; + /** + * Storage to Network Proximity. Provides storage to network proximity information for the + * volume. Possible values include: 'Default', 'T1', 'T2' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly storageToNetworkProximity?: VolumeStorageToNetworkProximity; /** * mountTargets. List of mount targets * **NOTE: This property will not be serialized. It can only be populated by the server.** */ readonly mountTargets?: MountTargetProperties[]; /** - * What type of volume is this + * What type of volume is this. For destination volumes in Cross Region Replication, set type to + * DataProtection */ volumeType?: string; /** @@ -1952,6 +2045,34 @@ export interface RestoreStatus { readonly totalTransferBytes?: number; } +/** + * The resource model definition for an Azure Resource Manager tracked top level resource which has + * 'tags' and a 'location' + * @summary Tracked Resource + */ +export interface TrackedResource extends Resource { + /** + * Resource tags. + */ + tags?: { [propertyName: string]: string }; + /** + * The geo-location where the resource lives + */ + location: string; +} + +/** + * The resource model definition for an Azure Resource Manager resource with an etag. + * @summary Entity Resource + */ +export interface AzureEntityResource extends Resource { + /** + * Resource Etag. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly etag?: string; +} + /** * Optional Parameters. */ @@ -2050,6 +2171,14 @@ export interface AzureNetAppFilesManagementClientOptions extends AzureServiceCli export interface OperationListResult extends Array { } +/** + * @interface + * List of Subscription Quota Items + * @extends Array + */ +export interface SubscriptionQuotaItemList extends Array { +} + /** * @interface * List of NetApp account resources @@ -2165,20 +2294,20 @@ export type CheckNameResourceTypes = 'Microsoft.NetApp/netAppAccounts' | 'Micros export type CheckQuotaNameResourceTypes = 'Microsoft.NetApp/netAppAccounts' | 'Microsoft.NetApp/netAppAccounts/capacityPools' | 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes' | 'Microsoft.NetApp/netAppAccounts/capacityPools/volumes/snapshots'; /** - * Defines values for ActiveDirectoryStatus. - * Possible values include: 'Created', 'InUse', 'Deleted', 'Error', 'Updating' + * Defines values for CreatedByType. + * Possible values include: 'User', 'Application', 'ManagedIdentity', 'Key' * @readonly * @enum {string} */ -export type ActiveDirectoryStatus = 'Created' | 'InUse' | 'Deleted' | 'Error' | 'Updating'; +export type CreatedByType = 'User' | 'Application' | 'ManagedIdentity' | 'Key'; /** - * Defines values for CreatedByType. - * Possible values include: 'User', 'Application', 'ManagedIdentity', 'Key' + * Defines values for ActiveDirectoryStatus. + * Possible values include: 'Created', 'InUse', 'Deleted', 'Error', 'Updating' * @readonly * @enum {string} */ -export type CreatedByType = 'User' | 'Application' | 'ManagedIdentity' | 'Key'; +export type ActiveDirectoryStatus = 'Created' | 'InUse' | 'Deleted' | 'Error' | 'Updating'; /** * Defines values for ServiceLevel. @@ -2212,6 +2341,22 @@ export type EncryptionType = 'Single' | 'Double'; */ export type ChownMode = 'Restricted' | 'Unrestricted'; +/** + * Defines values for NetworkFeatures. + * Possible values include: 'Basic', 'Standard' + * @readonly + * @enum {string} + */ +export type NetworkFeatures = 'Basic' | 'Standard'; + +/** + * Defines values for VolumeStorageToNetworkProximity. + * Possible values include: 'Default', 'T1', 'T2' + * @readonly + * @enum {string} + */ +export type VolumeStorageToNetworkProximity = 'Default' | 'T1' | 'T2'; + /** * Defines values for EndpointType. * Possible values include: 'src', 'dst' @@ -2348,6 +2493,46 @@ export type NetAppResourceCheckQuotaAvailabilityResponse = CheckAvailabilityResp }; }; +/** + * Contains response data for the list operation. + */ +export type NetAppResourceQuotaLimitsListResponse = SubscriptionQuotaItemList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: SubscriptionQuotaItemList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type NetAppResourceQuotaLimitsGetResponse = SubscriptionQuotaItem & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: SubscriptionQuotaItem; + }; +}; + /** * Contains response data for the listBySubscription operation. */ diff --git a/sdk/netapp/arm-netapp/src/models/mappers.ts b/sdk/netapp/arm-netapp/src/models/mappers.ts index 9b2ebef71116..f7a2c2334100 100644 --- a/sdk/netapp/arm-netapp/src/models/mappers.ts +++ b/sdk/netapp/arm-netapp/src/models/mappers.ts @@ -126,6 +126,12 @@ export const MetricSpecification: msRest.CompositeMapper = { name: "String" } }, + enableRegionalMdmAccount: { + serializedName: "enableRegionalMdmAccount", + type: { + name: "Boolean" + } + }, sourceMdmAccount: { serializedName: "sourceMdmAccount", type: { @@ -173,6 +179,34 @@ export const MetricSpecification: msRest.CompositeMapper = { type: { name: "String" } + }, + isInternal: { + serializedName: "isInternal", + type: { + name: "Boolean" + } + } + } + } +}; + +export const LogSpecification: msRest.CompositeMapper = { + serializedName: "LogSpecification", + type: { + name: "Composite", + className: "LogSpecification", + modelProperties: { + name: { + serializedName: "name", + type: { + name: "String" + } + }, + displayName: { + serializedName: "displayName", + type: { + name: "String" + } } } } @@ -195,6 +229,18 @@ export const ServiceSpecification: msRest.CompositeMapper = { } } } + }, + logSpecifications: { + serializedName: "logSpecifications", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "LogSpecification" + } + } + } } } } @@ -350,6 +396,134 @@ export const QuotaAvailabilityRequest: msRest.CompositeMapper = { } }; +export const SystemData: msRest.CompositeMapper = { + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData", + modelProperties: { + createdBy: { + serializedName: "createdBy", + type: { + name: "String" + } + }, + createdByType: { + serializedName: "createdByType", + type: { + name: "String" + } + }, + createdAt: { + serializedName: "createdAt", + type: { + name: "DateTime" + } + }, + lastModifiedBy: { + serializedName: "lastModifiedBy", + type: { + name: "String" + } + }, + lastModifiedByType: { + serializedName: "lastModifiedByType", + type: { + name: "String" + } + }, + lastModifiedAt: { + serializedName: "lastModifiedAt", + type: { + name: "DateTime" + } + } + } + } +}; + +export const Resource: msRest.CompositeMapper = { + serializedName: "Resource", + type: { + name: "Composite", + className: "Resource", + modelProperties: { + id: { + readOnly: true, + serializedName: "id", + type: { + name: "String" + } + }, + name: { + readOnly: true, + serializedName: "name", + type: { + name: "String" + } + }, + type: { + readOnly: true, + serializedName: "type", + type: { + name: "String" + } + } + } + } +}; + +export const ProxyResource: msRest.CompositeMapper = { + serializedName: "ProxyResource", + type: { + name: "Composite", + className: "ProxyResource", + modelProperties: { + ...Resource.type.modelProperties + } + } +}; + +export const SubscriptionQuotaItem: msRest.CompositeMapper = { + serializedName: "SubscriptionQuotaItem", + type: { + name: "Composite", + className: "SubscriptionQuotaItem", + modelProperties: { + ...ProxyResource.type.modelProperties, + subscriptionQuotaItemName: { + readOnly: true, + serializedName: "properties.name", + type: { + name: "String" + } + }, + current: { + readOnly: true, + serializedName: "properties.current", + type: { + name: "Number" + } + }, + default: { + readOnly: true, + serializedName: "properties.default", + type: { + name: "Number" + } + }, + systemData: { + readOnly: true, + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData" + } + } + } + } +}; + export const ActiveDirectory: msRest.CompositeMapper = { serializedName: "activeDirectory", type: { @@ -529,52 +703,6 @@ export const AccountEncryption: msRest.CompositeMapper = { } }; -export const SystemData: msRest.CompositeMapper = { - serializedName: "systemData", - type: { - name: "Composite", - className: "SystemData", - modelProperties: { - createdBy: { - serializedName: "createdBy", - type: { - name: "String" - } - }, - createdByType: { - serializedName: "createdByType", - type: { - name: "String" - } - }, - createdAt: { - serializedName: "createdAt", - type: { - name: "DateTime" - } - }, - lastModifiedBy: { - serializedName: "lastModifiedBy", - type: { - name: "String" - } - }, - lastModifiedByType: { - serializedName: "lastModifiedByType", - type: { - name: "String" - } - }, - lastModifiedAt: { - serializedName: "lastModifiedAt", - type: { - name: "DateTime" - } - } - } - } -}; - export const NetAppAccount: msRest.CompositeMapper = { serializedName: "netAppAccount", type: { @@ -1165,7 +1293,6 @@ export const ReplicationObject: msRest.CompositeMapper = { } }, replicationSchedule: { - required: true, serializedName: "replicationSchedule", type: { name: "String" @@ -1393,6 +1520,32 @@ export const Volume: msRest.CompositeMapper = { name: "String" } }, + networkFeatures: { + serializedName: "properties.networkFeatures", + defaultValue: 'Basic', + type: { + name: "String" + } + }, + networkSiblingSetId: { + readOnly: true, + serializedName: "properties.networkSiblingSetId", + constraints: { + MaxLength: 36, + MinLength: 36, + Pattern: /^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/ + }, + type: { + name: "String" + } + }, + storageToNetworkProximity: { + readOnly: true, + serializedName: "properties.storageToNetworkProximity", + type: { + name: "String" + } + }, mountTargets: { readOnly: true, serializedName: "properties.mountTargets", @@ -3163,6 +3316,53 @@ export const RestoreStatus: msRest.CompositeMapper = { } }; +export const TrackedResource: msRest.CompositeMapper = { + serializedName: "TrackedResource", + type: { + name: "Composite", + className: "TrackedResource", + modelProperties: { + ...Resource.type.modelProperties, + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { + type: { + name: "String" + } + } + } + }, + location: { + required: true, + serializedName: "location", + type: { + name: "String" + } + } + } + } +}; + +export const AzureEntityResource: msRest.CompositeMapper = { + serializedName: "AzureEntityResource", + type: { + name: "Composite", + className: "AzureEntityResource", + modelProperties: { + ...Resource.type.modelProperties, + etag: { + readOnly: true, + serializedName: "etag", + type: { + name: "String" + } + } + } + } +}; + export const OperationListResult: msRest.CompositeMapper = { serializedName: "OperationListResult", type: { @@ -3185,6 +3385,28 @@ export const OperationListResult: msRest.CompositeMapper = { } }; +export const SubscriptionQuotaItemList: msRest.CompositeMapper = { + serializedName: "SubscriptionQuotaItemList", + type: { + name: "Composite", + className: "SubscriptionQuotaItemList", + modelProperties: { + value: { + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SubscriptionQuotaItem" + } + } + } + } + } + } +}; + export const NetAppAccountList: msRest.CompositeMapper = { serializedName: "netAppAccountList", type: { diff --git a/sdk/netapp/arm-netapp/src/models/netAppResourceQuotaLimitsMappers.ts b/sdk/netapp/arm-netapp/src/models/netAppResourceQuotaLimitsMappers.ts new file mode 100644 index 000000000000..4f7cc3870945 --- /dev/null +++ b/sdk/netapp/arm-netapp/src/models/netAppResourceQuotaLimitsMappers.ts @@ -0,0 +1,49 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + AccountEncryption, + ActiveDirectory, + AzureEntityResource, + Backup, + BackupPatch, + BackupPolicy, + BackupPolicyDetails, + BackupPolicyPatch, + BaseResource, + CapacityPool, + CapacityPoolPatch, + CloudError, + DailySchedule, + ExportPolicyRule, + HourlySchedule, + MonthlySchedule, + MountTargetProperties, + NetAppAccount, + NetAppAccountPatch, + ProxyResource, + ReplicationObject, + Resource, + Snapshot, + SnapshotPolicy, + SubscriptionQuotaItem, + SubscriptionQuotaItemList, + SystemData, + TrackedResource, + Vault, + Volume, + VolumeBackupProperties, + VolumeBackups, + VolumePatch, + VolumePatchPropertiesDataProtection, + VolumePatchPropertiesExportPolicy, + VolumePropertiesDataProtection, + VolumePropertiesExportPolicy, + VolumeSnapshotProperties, + WeeklySchedule +} from "../models/mappers"; diff --git a/sdk/netapp/arm-netapp/src/models/operationsMappers.ts b/sdk/netapp/arm-netapp/src/models/operationsMappers.ts index 7998fd6a0db3..3b1367c577e4 100644 --- a/sdk/netapp/arm-netapp/src/models/operationsMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/operationsMappers.ts @@ -9,6 +9,7 @@ export { CloudError, Dimension, + LogSpecification, MetricSpecification, Operation, OperationDisplay, diff --git a/sdk/netapp/arm-netapp/src/models/parameters.ts b/sdk/netapp/arm-netapp/src/models/parameters.ts index 42db0c6d334b..196b741086bc 100644 --- a/sdk/netapp/arm-netapp/src/models/parameters.ts +++ b/sdk/netapp/arm-netapp/src/models/parameters.ts @@ -98,6 +98,16 @@ export const poolName: msRest.OperationURLParameter = { } } }; +export const quotaLimitName: msRest.OperationURLParameter = { + parameterPath: "quotaLimitName", + mapper: { + required: true, + serializedName: "quotaLimitName", + type: { + name: "String" + } + } +}; export const resourceGroupName: msRest.OperationURLParameter = { parameterPath: "resourceGroupName", mapper: { diff --git a/sdk/netapp/arm-netapp/src/models/poolsMappers.ts b/sdk/netapp/arm-netapp/src/models/poolsMappers.ts index 4cdb59961bbe..aa64a08a82a7 100644 --- a/sdk/netapp/arm-netapp/src/models/poolsMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/poolsMappers.ts @@ -9,6 +9,7 @@ export { AccountEncryption, ActiveDirectory, + AzureEntityResource, Backup, BackupPatch, BackupPolicy, @@ -26,10 +27,14 @@ export { MountTargetProperties, NetAppAccount, NetAppAccountPatch, + ProxyResource, ReplicationObject, + Resource, Snapshot, SnapshotPolicy, + SubscriptionQuotaItem, SystemData, + TrackedResource, Vault, Volume, VolumeBackupProperties, diff --git a/sdk/netapp/arm-netapp/src/models/snapshotPoliciesMappers.ts b/sdk/netapp/arm-netapp/src/models/snapshotPoliciesMappers.ts index 7fb7e27a0438..4bb30589037a 100644 --- a/sdk/netapp/arm-netapp/src/models/snapshotPoliciesMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/snapshotPoliciesMappers.ts @@ -9,6 +9,7 @@ export { AccountEncryption, ActiveDirectory, + AzureEntityResource, Backup, BackupPatch, BackupPolicy, @@ -25,13 +26,17 @@ export { MountTargetProperties, NetAppAccount, NetAppAccountPatch, + ProxyResource, ReplicationObject, + Resource, Snapshot, SnapshotPoliciesList, SnapshotPolicy, SnapshotPolicyPatch, SnapshotPolicyVolumeList, + SubscriptionQuotaItem, SystemData, + TrackedResource, Vault, Volume, VolumeBackupProperties, diff --git a/sdk/netapp/arm-netapp/src/models/snapshotsMappers.ts b/sdk/netapp/arm-netapp/src/models/snapshotsMappers.ts index b4063584ddd8..6ec1b2ff4be0 100644 --- a/sdk/netapp/arm-netapp/src/models/snapshotsMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/snapshotsMappers.ts @@ -9,6 +9,7 @@ export { AccountEncryption, ActiveDirectory, + AzureEntityResource, Backup, BackupPatch, BackupPolicy, @@ -25,11 +26,15 @@ export { MountTargetProperties, NetAppAccount, NetAppAccountPatch, + ProxyResource, ReplicationObject, + Resource, Snapshot, SnapshotPolicy, SnapshotsList, + SubscriptionQuotaItem, SystemData, + TrackedResource, Vault, Volume, VolumeBackupProperties, diff --git a/sdk/netapp/arm-netapp/src/models/vaultsMappers.ts b/sdk/netapp/arm-netapp/src/models/vaultsMappers.ts index f9615cb07883..037d3284c42b 100644 --- a/sdk/netapp/arm-netapp/src/models/vaultsMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/vaultsMappers.ts @@ -9,6 +9,7 @@ export { AccountEncryption, ActiveDirectory, + AzureEntityResource, Backup, BackupPatch, BackupPolicy, @@ -25,10 +26,14 @@ export { MountTargetProperties, NetAppAccount, NetAppAccountPatch, + ProxyResource, ReplicationObject, + Resource, Snapshot, SnapshotPolicy, + SubscriptionQuotaItem, SystemData, + TrackedResource, Vault, VaultList, Volume, diff --git a/sdk/netapp/arm-netapp/src/models/volumesMappers.ts b/sdk/netapp/arm-netapp/src/models/volumesMappers.ts index 2ec246d0704a..7db07db26e8c 100644 --- a/sdk/netapp/arm-netapp/src/models/volumesMappers.ts +++ b/sdk/netapp/arm-netapp/src/models/volumesMappers.ts @@ -10,6 +10,7 @@ export { AccountEncryption, ActiveDirectory, AuthorizeRequest, + AzureEntityResource, Backup, BackupPatch, BackupPolicy, @@ -28,11 +29,15 @@ export { NetAppAccount, NetAppAccountPatch, PoolChangeRequest, + ProxyResource, ReplicationObject, ReplicationStatus, + Resource, Snapshot, SnapshotPolicy, + SubscriptionQuotaItem, SystemData, + TrackedResource, Vault, Volume, VolumeBackupProperties, diff --git a/sdk/netapp/arm-netapp/src/operations/index.ts b/sdk/netapp/arm-netapp/src/operations/index.ts index bd1cd443318d..0dd40a92a893 100644 --- a/sdk/netapp/arm-netapp/src/operations/index.ts +++ b/sdk/netapp/arm-netapp/src/operations/index.ts @@ -9,6 +9,7 @@ export * from "./operations"; export * from "./netAppResource"; +export * from "./netAppResourceQuotaLimits"; export * from "./accounts"; export * from "./pools"; export * from "./volumes"; diff --git a/sdk/netapp/arm-netapp/src/operations/netAppResourceQuotaLimits.ts b/sdk/netapp/arm-netapp/src/operations/netAppResourceQuotaLimits.ts new file mode 100644 index 000000000000..7e48ba3003b5 --- /dev/null +++ b/sdk/netapp/arm-netapp/src/operations/netAppResourceQuotaLimits.ts @@ -0,0 +1,140 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as Models from "../models"; +import * as Mappers from "../models/netAppResourceQuotaLimitsMappers"; +import * as Parameters from "../models/parameters"; +import { AzureNetAppFilesManagementClientContext } from "../azureNetAppFilesManagementClientContext"; + +/** Class representing a NetAppResourceQuotaLimits. */ +export class NetAppResourceQuotaLimits { + private readonly client: AzureNetAppFilesManagementClientContext; + + /** + * Create a NetAppResourceQuotaLimits. + * @param {AzureNetAppFilesManagementClientContext} client Reference to the service client. + */ + constructor(client: AzureNetAppFilesManagementClientContext) { + this.client = client; + } + + /** + * Get the default and current limits for quotas + * @summary Get quota limits + * @param location The location + * @param [options] The optional parameters + * @returns Promise + */ + list(location: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param location The location + * @param callback The callback + */ + list(location: string, callback: msRest.ServiceCallback): void; + /** + * @param location The location + * @param options The optional parameters + * @param callback The callback + */ + list(location: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + list(location: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + location, + options + }, + listOperationSpec, + callback) as Promise; + } + + /** + * Get the default and current subscription quota limit + * @summary Get quota limits + * @param location The location + * @param quotaLimitName The name of the Quota Limit + * @param [options] The optional parameters + * @returns Promise + */ + get(location: string, quotaLimitName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param location The location + * @param quotaLimitName The name of the Quota Limit + * @param callback The callback + */ + get(location: string, quotaLimitName: string, callback: msRest.ServiceCallback): void; + /** + * @param location The location + * @param quotaLimitName The name of the Quota Limit + * @param options The optional parameters + * @param callback The callback + */ + get(location: string, quotaLimitName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(location: string, quotaLimitName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + location, + quotaLimitName, + options + }, + getOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/providers/Microsoft.NetApp/locations/{location}/quotaLimits", + urlParameters: [ + Parameters.subscriptionId, + Parameters.location + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.SubscriptionQuotaItemList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/providers/Microsoft.NetApp/locations/{location}/quotaLimits/{quotaLimitName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.location, + Parameters.quotaLimitName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.SubscriptionQuotaItem + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +};