From eefde489df84b779790826b734d48d4d3a5c89de Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Tue, 13 Apr 2021 00:38:24 +0000 Subject: [PATCH] CodeGen from PR 13777 in Azure/azure-rest-api-specs Merge bfda6f8c1725d691eba1ca241ca68e9bbf5a8fe2 into b3577207350270e9ae3b3e22c91b1730c602f276 --- .../src/mixedRealityClient.ts | 2 + .../src/mixedRealityClientContext.ts | 8 +- .../arm-mixedreality/src/models/index.ts | 269 +++++++- .../arm-mixedreality/src/models/mappers.ts | 155 +++++ .../models/objectAnchorsAccountsMappers.ts | 31 + .../models/remoteRenderingAccountsMappers.ts | 2 + .../models/spatialAnchorsAccountsMappers.ts | 2 + .../arm-mixedreality/src/operations/index.ts | 1 + .../src/operations/objectAnchorsAccounts.ts | 609 ++++++++++++++++++ 9 files changed, 1073 insertions(+), 6 deletions(-) create mode 100644 sdk/mixedreality/arm-mixedreality/src/models/objectAnchorsAccountsMappers.ts create mode 100644 sdk/mixedreality/arm-mixedreality/src/operations/objectAnchorsAccounts.ts diff --git a/sdk/mixedreality/arm-mixedreality/src/mixedRealityClient.ts b/sdk/mixedreality/arm-mixedreality/src/mixedRealityClient.ts index 2983d2d4fd0a..e1bfee2caeb5 100644 --- a/sdk/mixedreality/arm-mixedreality/src/mixedRealityClient.ts +++ b/sdk/mixedreality/arm-mixedreality/src/mixedRealityClient.ts @@ -20,6 +20,7 @@ class MixedRealityClient extends MixedRealityClientContext { operations: operations.Operations; spatialAnchorsAccounts: operations.SpatialAnchorsAccounts; remoteRenderingAccounts: operations.RemoteRenderingAccounts; + objectAnchorsAccounts: operations.ObjectAnchorsAccounts; /** * Initializes a new instance of the MixedRealityClient class. @@ -33,6 +34,7 @@ class MixedRealityClient extends MixedRealityClientContext { this.operations = new operations.Operations(this); this.spatialAnchorsAccounts = new operations.SpatialAnchorsAccounts(this); this.remoteRenderingAccounts = new operations.RemoteRenderingAccounts(this); + this.objectAnchorsAccounts = new operations.ObjectAnchorsAccounts(this); } /** diff --git a/sdk/mixedreality/arm-mixedreality/src/mixedRealityClientContext.ts b/sdk/mixedreality/arm-mixedreality/src/mixedRealityClientContext.ts index 16b8190b3d87..75313695f2a0 100644 --- a/sdk/mixedreality/arm-mixedreality/src/mixedRealityClientContext.ts +++ b/sdk/mixedreality/arm-mixedreality/src/mixedRealityClientContext.ts @@ -37,14 +37,14 @@ export class MixedRealityClientContext extends msRestAzure.AzureServiceClient { if (!options) { options = {}; } - if (!options.userAgent) { + if(!options.userAgent) { const defaultUserAgent = msRestAzure.getDefaultUserAgentValue(); options.userAgent = `${packageName}/${packageVersion} ${defaultUserAgent}`; } super(credentials, options); - this.apiVersion = '2021-01-01'; + this.apiVersion = '2021-03-01-preview'; this.acceptLanguage = 'en-US'; this.longRunningOperationRetryTimeout = 30; this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com"; @@ -52,10 +52,10 @@ export class MixedRealityClientContext extends msRestAzure.AzureServiceClient { this.credentials = credentials; this.subscriptionId = subscriptionId; - if (options.acceptLanguage !== null && options.acceptLanguage !== undefined) { + if(options.acceptLanguage !== null && options.acceptLanguage !== undefined) { this.acceptLanguage = options.acceptLanguage; } - if (options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) { + if(options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) { this.longRunningOperationRetryTimeout = options.longRunningOperationRetryTimeout; } } diff --git a/sdk/mixedreality/arm-mixedreality/src/models/index.ts b/sdk/mixedreality/arm-mixedreality/src/models/index.ts index 4e28b8df1c98..0bad09102cc4 100644 --- a/sdk/mixedreality/arm-mixedreality/src/models/index.ts +++ b/sdk/mixedreality/arm-mixedreality/src/models/index.ts @@ -99,6 +99,10 @@ export interface MetricDimension { * Internal name of the dimension. */ internalName?: string; + /** + * Flag to indicate export for Shoebox + */ + toBeExportedForShoebox?: boolean; } /** @@ -125,6 +129,38 @@ export interface MetricSpecification { * Only provide one value for this field. Valid values: Average, Minimum, Maximum, Total, Count. */ aggregationType?: string; + /** + * Supported aggregation types. Valid values: Average, Minimum, Maximum, Total, Count. + */ + supportedAggregationTypes?: string[]; + /** + * Supported time grains. Valid values: PT1M, PT5M, PT15M, PT30M, PT1H, PT6H, PT12H, P1D + */ + supportedTimeGrainTypes?: string[]; + /** + * Flag to indicate use of regional Mdm accounts + */ + enableRegionalMdmAccount?: boolean; + /** + * Source mdm account + */ + sourceMdmAccount?: string; + /** + * Source mdm namespace + */ + sourceMdmNamespace?: string; + /** + * Metric filter regex pattern + */ + metricFilterPattern?: string; + /** + * Flag to determine is Zero is returned for time duration where no metric is emitted + */ + fillGapWithZero?: boolean; + /** + * Metric category + */ + category?: string; /** * Internal metric name. */ @@ -133,6 +169,10 @@ export interface MetricSpecification { * Dimensions of the metric */ dimensions?: MetricDimension[]; + /** + * Locked aggregation type of the metric + */ + lockedAggregationType?: string; } /** @@ -263,7 +303,7 @@ export interface SystemData { */ lastModifiedByType?: CreatedByType; /** - * The type of identity that last modified the resource. + * The timestamp of resource last modification (UTC) */ lastModifiedAt?: Date; } @@ -492,7 +532,7 @@ export interface AccountKeys { */ export interface AccountKeyRegenerateRequest { /** - * serial of key to be regenerated. Default value: 1. + * Serial of key to be regenerated. Default value: 1. */ serial?: number; } @@ -537,6 +577,38 @@ export interface RemoteRenderingAccount extends TrackedResource { systemData?: SystemData; } +/** + * An interface representing ObjectAnchorsAccountIdentity. + */ +export interface ObjectAnchorsAccountIdentity extends Identity { +} + +/** + * ObjectAnchorsAccount Response. + */ +export interface ObjectAnchorsAccount extends TrackedResource { + identity?: ObjectAnchorsAccountIdentity; + /** + * The name of the storage account associated with this accountId + */ + storageAccountName?: string; + /** + * unique id of certain account. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly accountId?: string; + /** + * Correspond domain name of certain Spatial Anchors Account + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly accountDomain?: string; + /** + * The system metadata related to an object anchors account. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly systemData?: SystemData; +} + /** * An interface representing MixedRealityClientOptions. */ @@ -583,6 +655,19 @@ export interface RemoteRenderingAccountPage extends Array + */ +export interface ObjectAnchorsAccountPage extends Array { + /** + * URL to get the next set of resource list results if there are any. + */ + nextLink?: string; +} + /** * Defines values for NameUnavailableReason. * Possible values include: 'Invalid', 'AlreadyExists' @@ -1034,3 +1119,183 @@ export type RemoteRenderingAccountsListByResourceGroupNextResponse = RemoteRende parsedBody: RemoteRenderingAccountPage; }; }; + +/** + * Contains response data for the listBySubscription operation. + */ +export type ObjectAnchorsAccountsListBySubscriptionResponse = ObjectAnchorsAccountPage & { + /** + * 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: ObjectAnchorsAccountPage; + }; +}; + +/** + * Contains response data for the listByResourceGroup operation. + */ +export type ObjectAnchorsAccountsListByResourceGroupResponse = ObjectAnchorsAccountPage & { + /** + * 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: ObjectAnchorsAccountPage; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type ObjectAnchorsAccountsGetResponse = ObjectAnchorsAccount & { + /** + * 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: ObjectAnchorsAccount; + }; +}; + +/** + * Contains response data for the update operation. + */ +export type ObjectAnchorsAccountsUpdateResponse = ObjectAnchorsAccount & { + /** + * 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: ObjectAnchorsAccount; + }; +}; + +/** + * Contains response data for the create operation. + */ +export type ObjectAnchorsAccountsCreateResponse = ObjectAnchorsAccount & { + /** + * 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: ObjectAnchorsAccount; + }; +}; + +/** + * Contains response data for the listKeys operation. + */ +export type ObjectAnchorsAccountsListKeysResponse = AccountKeys & { + /** + * 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: AccountKeys; + }; +}; + +/** + * Contains response data for the regenerateKeys operation. + */ +export type ObjectAnchorsAccountsRegenerateKeysResponse = AccountKeys & { + /** + * 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: AccountKeys; + }; +}; + +/** + * Contains response data for the listBySubscriptionNext operation. + */ +export type ObjectAnchorsAccountsListBySubscriptionNextResponse = ObjectAnchorsAccountPage & { + /** + * 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: ObjectAnchorsAccountPage; + }; +}; + +/** + * Contains response data for the listByResourceGroupNext operation. + */ +export type ObjectAnchorsAccountsListByResourceGroupNextResponse = ObjectAnchorsAccountPage & { + /** + * 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: ObjectAnchorsAccountPage; + }; +}; diff --git a/sdk/mixedreality/arm-mixedreality/src/models/mappers.ts b/sdk/mixedreality/arm-mixedreality/src/models/mappers.ts index 9d6736c499e9..fa578030c94f 100644 --- a/sdk/mixedreality/arm-mixedreality/src/models/mappers.ts +++ b/sdk/mixedreality/arm-mixedreality/src/models/mappers.ts @@ -154,6 +154,12 @@ export const MetricDimension: msRest.CompositeMapper = { type: { name: "String" } + }, + toBeExportedForShoebox: { + serializedName: "toBeExportedForShoebox", + type: { + name: "Boolean" + } } } } @@ -195,6 +201,64 @@ export const MetricSpecification: msRest.CompositeMapper = { name: "String" } }, + supportedAggregationTypes: { + serializedName: "supportedAggregationTypes", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + supportedTimeGrainTypes: { + serializedName: "supportedTimeGrainTypes", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + enableRegionalMdmAccount: { + serializedName: "enableRegionalMdmAccount", + type: { + name: "Boolean" + } + }, + sourceMdmAccount: { + serializedName: "sourceMdmAccount", + type: { + name: "String" + } + }, + sourceMdmNamespace: { + serializedName: "sourceMdmNamespace", + type: { + name: "String" + } + }, + metricFilterPattern: { + serializedName: "metricFilterPattern", + type: { + name: "String" + } + }, + fillGapWithZero: { + serializedName: "fillGapWithZero", + type: { + name: "Boolean" + } + }, + category: { + serializedName: "category", + type: { + name: "String" + } + }, internalMetricName: { serializedName: "internalMetricName", type: { @@ -212,6 +276,12 @@ export const MetricSpecification: msRest.CompositeMapper = { } } } + }, + lockedAggregationType: { + serializedName: "lockedAggregationType", + type: { + name: "String" + } } } } @@ -865,6 +935,63 @@ export const RemoteRenderingAccount: msRest.CompositeMapper = { } }; +export const ObjectAnchorsAccountIdentity: msRest.CompositeMapper = { + serializedName: "ObjectAnchorsAccount_identity", + type: { + name: "Composite", + className: "ObjectAnchorsAccountIdentity", + modelProperties: { + ...Identity.type.modelProperties + } + } +}; + +export const ObjectAnchorsAccount: msRest.CompositeMapper = { + serializedName: "ObjectAnchorsAccount", + type: { + name: "Composite", + className: "ObjectAnchorsAccount", + modelProperties: { + ...TrackedResource.type.modelProperties, + identity: { + serializedName: "identity", + type: { + name: "Composite", + className: "ObjectAnchorsAccountIdentity" + } + }, + storageAccountName: { + serializedName: "properties.storageAccountName", + type: { + name: "String" + } + }, + accountId: { + readOnly: true, + serializedName: "properties.accountId", + type: { + name: "String" + } + }, + accountDomain: { + readOnly: true, + serializedName: "properties.accountDomain", + type: { + name: "String" + } + }, + systemData: { + readOnly: true, + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData" + } + } + } + } +}; + export const OperationPage: msRest.CompositeMapper = { serializedName: "OperationPage", type: { @@ -948,3 +1075,31 @@ export const RemoteRenderingAccountPage: msRest.CompositeMapper = { } } }; + +export const ObjectAnchorsAccountPage: msRest.CompositeMapper = { + serializedName: "ObjectAnchorsAccountPage", + type: { + name: "Composite", + className: "ObjectAnchorsAccountPage", + modelProperties: { + value: { + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ObjectAnchorsAccount" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; diff --git a/sdk/mixedreality/arm-mixedreality/src/models/objectAnchorsAccountsMappers.ts b/sdk/mixedreality/arm-mixedreality/src/models/objectAnchorsAccountsMappers.ts new file mode 100644 index 000000000000..58890aceca94 --- /dev/null +++ b/sdk/mixedreality/arm-mixedreality/src/models/objectAnchorsAccountsMappers.ts @@ -0,0 +1,31 @@ +/* + * 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 { + AccountKeyRegenerateRequest, + AccountKeys, + AzureEntityResource, + BaseResource, + CloudError, + Identity, + ObjectAnchorsAccount, + ObjectAnchorsAccountIdentity, + ObjectAnchorsAccountPage, + Plan, + ProxyResource, + RemoteRenderingAccount, + Resource, + ResourceModelWithAllowedPropertySet, + ResourceModelWithAllowedPropertySetIdentity, + ResourceModelWithAllowedPropertySetPlan, + ResourceModelWithAllowedPropertySetSku, + Sku, + SpatialAnchorsAccount, + SystemData, + TrackedResource +} from "../models/mappers"; diff --git a/sdk/mixedreality/arm-mixedreality/src/models/remoteRenderingAccountsMappers.ts b/sdk/mixedreality/arm-mixedreality/src/models/remoteRenderingAccountsMappers.ts index 37f1f372255f..06a5901d65f3 100644 --- a/sdk/mixedreality/arm-mixedreality/src/models/remoteRenderingAccountsMappers.ts +++ b/sdk/mixedreality/arm-mixedreality/src/models/remoteRenderingAccountsMappers.ts @@ -13,6 +13,8 @@ export { BaseResource, CloudError, Identity, + ObjectAnchorsAccount, + ObjectAnchorsAccountIdentity, Plan, ProxyResource, RemoteRenderingAccount, diff --git a/sdk/mixedreality/arm-mixedreality/src/models/spatialAnchorsAccountsMappers.ts b/sdk/mixedreality/arm-mixedreality/src/models/spatialAnchorsAccountsMappers.ts index 9ca78538adc7..a1fc252edf40 100644 --- a/sdk/mixedreality/arm-mixedreality/src/models/spatialAnchorsAccountsMappers.ts +++ b/sdk/mixedreality/arm-mixedreality/src/models/spatialAnchorsAccountsMappers.ts @@ -13,6 +13,8 @@ export { BaseResource, CloudError, Identity, + ObjectAnchorsAccount, + ObjectAnchorsAccountIdentity, Plan, ProxyResource, RemoteRenderingAccount, diff --git a/sdk/mixedreality/arm-mixedreality/src/operations/index.ts b/sdk/mixedreality/arm-mixedreality/src/operations/index.ts index 12d483f65a2f..7e7eea14b016 100644 --- a/sdk/mixedreality/arm-mixedreality/src/operations/index.ts +++ b/sdk/mixedreality/arm-mixedreality/src/operations/index.ts @@ -10,3 +10,4 @@ export * from "./operations"; export * from "./spatialAnchorsAccounts"; export * from "./remoteRenderingAccounts"; +export * from "./objectAnchorsAccounts"; diff --git a/sdk/mixedreality/arm-mixedreality/src/operations/objectAnchorsAccounts.ts b/sdk/mixedreality/arm-mixedreality/src/operations/objectAnchorsAccounts.ts new file mode 100644 index 000000000000..aedbbf50f7bb --- /dev/null +++ b/sdk/mixedreality/arm-mixedreality/src/operations/objectAnchorsAccounts.ts @@ -0,0 +1,609 @@ +/* + * 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/objectAnchorsAccountsMappers"; +import * as Parameters from "../models/parameters"; +import { MixedRealityClientContext } from "../mixedRealityClientContext"; + +/** Class representing a ObjectAnchorsAccounts. */ +export class ObjectAnchorsAccounts { + private readonly client: MixedRealityClientContext; + + /** + * Create a ObjectAnchorsAccounts. + * @param {MixedRealityClientContext} client Reference to the service client. + */ + constructor(client: MixedRealityClientContext) { + this.client = client; + } + + /** + * List Object Anchors Accounts by Subscription + * @param [options] The optional parameters + * @returns Promise + */ + listBySubscription(options?: msRest.RequestOptionsBase): Promise; + /** + * @param callback The callback + */ + listBySubscription(callback: msRest.ServiceCallback): void; + /** + * @param options The optional parameters + * @param callback The callback + */ + listBySubscription(options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listBySubscription(options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + options + }, + listBySubscriptionOperationSpec, + callback) as Promise; + } + + /** + * List Resources by Resource Group + * @param resourceGroupName Name of an Azure resource group. + * @param [options] The optional parameters + * @returns Promise + */ + listByResourceGroup(resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param callback The callback + */ + listByResourceGroup(resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param options The optional parameters + * @param callback The callback + */ + listByResourceGroup(resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + options + }, + listByResourceGroupOperationSpec, + callback) as Promise; + } + + /** + * Delete an Object Anchors Account. + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param callback The callback + */ + deleteMethod(resourceGroupName: string, accountName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param options The optional parameters + * @param callback The callback + */ + deleteMethod(resourceGroupName: string, accountName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + deleteMethod(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + options + }, + deleteMethodOperationSpec, + callback); + } + + /** + * Retrieve an Object Anchors Account. + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param callback The callback + */ + get(resourceGroupName: string, accountName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, accountName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Updating an Object Anchors Account + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param objectAnchorsAccount Object Anchors Account parameter. + * @param [options] The optional parameters + * @returns Promise + */ + update(resourceGroupName: string, accountName: string, objectAnchorsAccount: Models.ObjectAnchorsAccount, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param objectAnchorsAccount Object Anchors Account parameter. + * @param callback The callback + */ + update(resourceGroupName: string, accountName: string, objectAnchorsAccount: Models.ObjectAnchorsAccount, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param objectAnchorsAccount Object Anchors Account parameter. + * @param options The optional parameters + * @param callback The callback + */ + update(resourceGroupName: string, accountName: string, objectAnchorsAccount: Models.ObjectAnchorsAccount, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + update(resourceGroupName: string, accountName: string, objectAnchorsAccount: Models.ObjectAnchorsAccount, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + objectAnchorsAccount, + options + }, + updateOperationSpec, + callback) as Promise; + } + + /** + * Creating or Updating an object anchors Account. + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param objectAnchorsAccount Object Anchors Account parameter. + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, accountName: string, objectAnchorsAccount: Models.ObjectAnchorsAccount, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param objectAnchorsAccount Object Anchors Account parameter. + * @param callback The callback + */ + create(resourceGroupName: string, accountName: string, objectAnchorsAccount: Models.ObjectAnchorsAccount, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param objectAnchorsAccount Object Anchors Account parameter. + * @param options The optional parameters + * @param callback The callback + */ + create(resourceGroupName: string, accountName: string, objectAnchorsAccount: Models.ObjectAnchorsAccount, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + create(resourceGroupName: string, accountName: string, objectAnchorsAccount: Models.ObjectAnchorsAccount, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + objectAnchorsAccount, + options + }, + createOperationSpec, + callback) as Promise; + } + + /** + * List Both of the 2 Keys of an object anchors Account + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param [options] The optional parameters + * @returns Promise + */ + listKeys(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param callback The callback + */ + listKeys(resourceGroupName: string, accountName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param options The optional parameters + * @param callback The callback + */ + listKeys(resourceGroupName: string, accountName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listKeys(resourceGroupName: string, accountName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + options + }, + listKeysOperationSpec, + callback) as Promise; + } + + /** + * Regenerate specified Key of an object anchors Account + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param regenerate Required information for key regeneration. + * @param [options] The optional parameters + * @returns Promise + */ + regenerateKeys(resourceGroupName: string, accountName: string, regenerate: Models.AccountKeyRegenerateRequest, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param regenerate Required information for key regeneration. + * @param callback The callback + */ + regenerateKeys(resourceGroupName: string, accountName: string, regenerate: Models.AccountKeyRegenerateRequest, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of an Azure resource group. + * @param accountName Name of an Mixed Reality Account. + * @param regenerate Required information for key regeneration. + * @param options The optional parameters + * @param callback The callback + */ + regenerateKeys(resourceGroupName: string, accountName: string, regenerate: Models.AccountKeyRegenerateRequest, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + regenerateKeys(resourceGroupName: string, accountName: string, regenerate: Models.AccountKeyRegenerateRequest, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + accountName, + regenerate, + options + }, + regenerateKeysOperationSpec, + callback) as Promise; + } + + /** + * List Object Anchors Accounts by Subscription + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listBySubscriptionNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listBySubscriptionNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listBySubscriptionNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listBySubscriptionNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listBySubscriptionNextOperationSpec, + callback) as Promise; + } + + /** + * List Resources by Resource Group + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByResourceGroupNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByResourceGroupNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByResourceGroupNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByResourceGroupNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listBySubscriptionOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/providers/Microsoft.MixedReality/objectAnchorsAccounts", + urlParameters: [ + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ObjectAnchorsAccountPage + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByResourceGroupOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MixedReality/objectAnchorsAccounts", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ObjectAnchorsAccountPage + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const deleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MixedReality/objectAnchorsAccounts/{accountName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MixedReality/objectAnchorsAccounts/{accountName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ObjectAnchorsAccount + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const updateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MixedReality/objectAnchorsAccounts/{accountName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "objectAnchorsAccount", + mapper: { + ...Mappers.ObjectAnchorsAccount, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.ObjectAnchorsAccount + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const createOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MixedReality/objectAnchorsAccounts/{accountName}", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "objectAnchorsAccount", + mapper: { + ...Mappers.ObjectAnchorsAccount, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.ObjectAnchorsAccount + }, + 201: { + bodyMapper: Mappers.ObjectAnchorsAccount + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listKeysOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MixedReality/objectAnchorsAccounts/{accountName}/listKeys", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AccountKeys + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const regenerateKeysOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MixedReality/objectAnchorsAccounts/{accountName}/regenerateKeys", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName, + Parameters.accountName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "regenerate", + mapper: { + ...Mappers.AccountKeyRegenerateRequest, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.AccountKeys + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listBySubscriptionNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ObjectAnchorsAccountPage + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByResourceGroupNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ObjectAnchorsAccountPage + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +};