import { PagedAsyncIterableIterator } from "@azure/core-paging" ; import { Resources } from "../operationsInterfaces" ; import * as coreClient from "@azure/core-client" ; import * as Mappers from "../models/mappers" ; import * as Parameters from "../models/parameters" ; import { ResourceManagementClient } from "../resourceManagementClient" ; import { PollerLike , PollOperationState , LroEngine } from "@azure/core-lro" ; import { LroImpl } from "../lroImpl" ; import { GenericResourceExpanded , ResourcesListByResourceGroupNextOptionalParams , ResourcesListByResourceGroupOptionalParams , ResourcesListNextOptionalParams , ResourcesListOptionalParams , ResourcesListByResourceGroupResponse , ResourcesMoveInfo , ResourcesMoveResourcesOptionalParams , ResourcesValidateMoveResourcesOptionalParams , ResourcesListResponse , ResourcesCheckExistenceOptionalParams , ResourcesDeleteOptionalParams , GenericResource , ResourcesCreateOrUpdateOptionalParams , ResourcesCreateOrUpdateResponse , ResourcesUpdateOptionalParams , ResourcesUpdateResponse , ResourcesGetOptionalParams , ResourcesGetResponse , ResourcesCheckExistenceByIdOptionalParams , ResourcesDeleteByIdOptionalParams , ResourcesCreateOrUpdateByIdOptionalParams , ResourcesCreateOrUpdateByIdResponse , ResourcesUpdateByIdOptionalParams , ResourcesUpdateByIdResponse , ResourcesGetByIdOptionalParams , ResourcesGetByIdResponse , ResourcesListByResourceGroupNextResponse , ResourcesListNextResponse } from "../models" ; /** Class containing Resources operations. */ export class ResourcesImpl implements Resources { private readonly client : ResourceManagementClient ; param client constructor ( client ) { this . client = client ; } param resourceGroupName param options public listByResourceGroup ( resourceGroupName , options ? ) { const iter = this . listByResourceGroupPagingAll ( resourceGroupName , options ) ; return { next ( ) { return iter . next ( ) ; } , [ Symbol . asyncIterator ] ( ) { return this ; } , byPage : ( ) => { return this . listByResourceGroupPagingPage ( resourceGroupName , options ) ; } } ; } private async * listByResourceGroupPagingPage ( resourceGroupName , options ? ) { let result = await this . _listByResourceGroup ( resourceGroupName , options ) ; yield result . value || [ ] ; let continuationToken = result . nextLink ; while ( continuationToken ) { result = await this . _listByResourceGroupNext ( resourceGroupName , continuationToken , options ) ; continuationToken = result . nextLink ; yield result . value || [ ] ; } } private async * listByResourceGroupPagingAll ( resourceGroupName , options ? ) { for await ( const page of this . listByResourceGroupPagingPage ( resourceGroupName , options ) ) { yield * page ; } } param options public list ( options ? ) { const iter = this . listPagingAll ( options ) ; return { next ( ) { return iter . next ( ) ; } , [ Symbol . asyncIterator ] ( ) { return this ; } , byPage : ( ) => { return this . listPagingPage ( options ) ; } } ; } private async * listPagingPage ( options ? ) { let result = await this . _list ( options ) ; yield result . value || [ ] ; let continuationToken = result . nextLink ; while ( continuationToken ) { result = await this . _listNext ( continuationToken , options ) ; continuationToken = result . nextLink ; yield result . value || [ ] ; } } private async * listPagingAll ( options ? ) { for await ( const page of this . listPagingPage ( options ) ) { yield * page ; } } param resourceGroupName param options private _listByResourceGroup ( resourceGroupName , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , options } , listByResourceGroupOperationSpec ) ; } param sourceResourceGroupName param parameters param options async beginMoveResources ( sourceResourceGroupName , parameters , options ? ) { const directSendOperation = async ( args , spec ) : Promise < void > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { sourceResourceGroupName , parameters , options } , moveResourcesOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param sourceResourceGroupName param parameters param options async beginMoveResourcesAndWait ( sourceResourceGroupName , parameters , options ? ) { const poller = await this . beginMoveResources ( sourceResourceGroupName , parameters , options ) ; return poller . pollUntilDone ( ) ; } param sourceResourceGroupName param parameters param options async beginValidateMoveResources ( sourceResourceGroupName , parameters , options ? ) { const directSendOperation = async ( args , spec ) : Promise < void > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { sourceResourceGroupName , parameters , options } , validateMoveResourcesOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param sourceResourceGroupName param parameters param options async beginValidateMoveResourcesAndWait ( sourceResourceGroupName , parameters , options ? ) { const poller = await this . beginValidateMoveResources ( sourceResourceGroupName , parameters , options ) ; return poller . pollUntilDone ( ) ; } param options private _list ( options ? ) { return this . client . sendOperationRequest ( { options } , listOperationSpec ) ; } param resourceGroupName param resourceProviderNamespace param parentResourcePath param resourceType param resourceName param apiVersion param options checkExistence ( resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , options } , checkExistenceOperationSpec ) ; } param resourceGroupName param resourceProviderNamespace param parentResourcePath param resourceType param resourceName param apiVersion param options async beginDelete ( resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , options ? ) { const directSendOperation = async ( args , spec ) : Promise < void > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , options } , deleteOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceGroupName param resourceProviderNamespace param parentResourcePath param resourceType param resourceName param apiVersion param options async beginDeleteAndWait ( resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , options ? ) { const poller = await this . beginDelete ( resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , options ) ; return poller . pollUntilDone ( ) ; } param resourceGroupName param resourceProviderNamespace param parentResourcePath param resourceType param resourceName param apiVersion param parameters param options async beginCreateOrUpdate ( resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , parameters , options ? ) { const directSendOperation = async ( args , spec ) : Promise < ResourcesCreateOrUpdateResponse > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , parameters , options } , createOrUpdateOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceGroupName param resourceProviderNamespace param parentResourcePath param resourceType param resourceName param apiVersion param parameters param options async beginCreateOrUpdateAndWait ( resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , parameters , options ? ) { const poller = await this . beginCreateOrUpdate ( resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , parameters , options ) ; return poller . pollUntilDone ( ) ; } param resourceGroupName param resourceProviderNamespace param parentResourcePath param resourceType param resourceName param apiVersion param parameters param options async beginUpdate ( resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , parameters , options ? ) { const directSendOperation = async ( args , spec ) : Promise < ResourcesUpdateResponse > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , parameters , options } , updateOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceGroupName param resourceProviderNamespace param parentResourcePath param resourceType param resourceName param apiVersion param parameters param options async beginUpdateAndWait ( resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , parameters , options ? ) { const poller = await this . beginUpdate ( resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , parameters , options ) ; return poller . pollUntilDone ( ) ; } param resourceGroupName param resourceProviderNamespace param parentResourcePath param resourceType param resourceName param apiVersion param options get ( resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , resourceProviderNamespace , parentResourcePath , resourceType , resourceName , apiVersion , options } , getOperationSpec ) ; } param resourceId param apiVersion param options checkExistenceById ( resourceId , apiVersion , options ? ) { return this . client . sendOperationRequest ( { resourceId , apiVersion , options } , checkExistenceByIdOperationSpec ) ; } param resourceId param apiVersion param options async beginDeleteById ( resourceId , apiVersion , options ? ) { const directSendOperation = async ( args , spec ) : Promise < void > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { resourceId , apiVersion , options } , deleteByIdOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceId param apiVersion param options async beginDeleteByIdAndWait ( resourceId , apiVersion , options ? ) { const poller = await this . beginDeleteById ( resourceId , apiVersion , options ) ; return poller . pollUntilDone ( ) ; } param resourceId param apiVersion param parameters param options async beginCreateOrUpdateById ( resourceId , apiVersion , parameters , options ? ) { const directSendOperation = async ( args , spec ) : Promise < ResourcesCreateOrUpdateByIdResponse > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { resourceId , apiVersion , parameters , options } , createOrUpdateByIdOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceId param apiVersion param parameters param options async beginCreateOrUpdateByIdAndWait ( resourceId , apiVersion , parameters , options ? ) { const poller = await this . beginCreateOrUpdateById ( resourceId , apiVersion , parameters , options ) ; return poller . pollUntilDone ( ) ; } param resourceId param apiVersion param parameters param options async beginUpdateById ( resourceId , apiVersion , parameters , options ? ) { const directSendOperation = async ( args , spec ) : Promise < ResourcesUpdateByIdResponse > => { return this . client . sendOperationRequest ( args , spec ) ; } ; const sendOperation = async ( args , spec ) => { let currentRawResponse = undefined ; const providedCallback = args . options ?. onResponse ; const callback = ( rawResponse , flatResponse ) => { currentRawResponse = rawResponse ; providedCallback ?. ( rawResponse , flatResponse ) ; } ; const updatedArgs = { ... args , options : { ... args . options , onResponse : callback } } ; const flatResponse = await directSendOperation ( updatedArgs , spec ) ; return { flatResponse , rawResponse : { statusCode : currentRawResponse ! . status , body : currentRawResponse ! . parsedBody , headers : currentRawResponse ! . headers . toJSON ( ) } } ; } ; const lro = new LroImpl ( sendOperation , { resourceId , apiVersion , parameters , options } , updateByIdOperationSpec ) ; return new LroEngine ( lro , { resumeFrom : options ?. resumeFrom , intervalInMs : options ?. updateIntervalInMs } ) ; } param resourceId param apiVersion param parameters param options async beginUpdateByIdAndWait ( resourceId , apiVersion , parameters , options ? ) { const poller = await this . beginUpdateById ( resourceId , apiVersion , parameters , options ) ; return poller . pollUntilDone ( ) ; } param resourceId param apiVersion param options getById ( resourceId , apiVersion , options ? ) { return this . client . sendOperationRequest ( { resourceId , apiVersion , options } , getByIdOperationSpec ) ; } param resourceGroupName param nextLink param options private _listByResourceGroupNext ( resourceGroupName , nextLink , options ? ) { return this . client . sendOperationRequest ( { resourceGroupName , nextLink , options } , listByResourceGroupNextOperationSpec ) ; } param nextLink param options private _listNext ( nextLink , options ? ) { return this . client . sendOperationRequest ( { nextLink , options } , listNextOperationSpec ) ; } } const serializer = coreClient . createSerializer ( Mappers , false ) ; const listByResourceGroupOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/resources" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . ResourceListResult } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion , Parameters . filter , Parameters . top , Parameters . expand ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName ] , headerParameters : [ Parameters . accept ] , serializer } ; const moveResourcesOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{sourceResourceGroupName}/moveResources" , httpMethod : "POST" , responses : { 200 : { } , 201 : { } , 202 : { } , 204 : { } , default : { bodyMapper : Mappers . CloudError } } , requestBody : Parameters . parameters3 , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . sourceResourceGroupName ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const validateMoveResourcesOperationSpec = { path : "/subscriptions/{subscriptionId}/resourceGroups/{sourceResourceGroupName}/validateMoveResources" , httpMethod : "POST" , responses : { 200 : { } , 201 : { } , 202 : { } , 204 : { } , default : { bodyMapper : Mappers . CloudError } } , requestBody : Parameters . parameters3 , queryParameters : [ Parameters . apiVersion ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . sourceResourceGroupName ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const listOperationSpec = { path : "/subscriptions/{subscriptionId}/resources" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . ResourceListResult } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion , Parameters . filter , Parameters . top , Parameters . expand ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId ] , headerParameters : [ Parameters . accept ] , serializer } ; const checkExistenceOperationSpec = { path : "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}" , httpMethod : "HEAD" , responses : { 204 : { } , 404 : { } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion1 ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . resourceProviderNamespace , Parameters . parentResourcePath , Parameters . resourceType , Parameters . resourceName ] , headerParameters : [ Parameters . accept ] , serializer } ; const deleteOperationSpec = { path : "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}" , httpMethod : "DELETE" , responses : { 200 : { } , 201 : { } , 202 : { } , 204 : { } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion1 ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . resourceProviderNamespace , Parameters . parentResourcePath , Parameters . resourceType , Parameters . resourceName ] , headerParameters : [ Parameters . accept ] , serializer } ; const createOrUpdateOperationSpec = { path : "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}" , httpMethod : "PUT" , responses : { 200 : { bodyMapper : Mappers . GenericResource } , 201 : { bodyMapper : Mappers . GenericResource } , 202 : { bodyMapper : Mappers . GenericResource } , 204 : { bodyMapper : Mappers . GenericResource } , default : { bodyMapper : Mappers . CloudError } } , requestBody : Parameters . parameters4 , queryParameters : [ Parameters . apiVersion1 ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . resourceProviderNamespace , Parameters . parentResourcePath , Parameters . resourceType , Parameters . resourceName ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const updateOperationSpec = { path : "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}" , httpMethod : "PATCH" , responses : { 200 : { bodyMapper : Mappers . GenericResource } , 201 : { bodyMapper : Mappers . GenericResource } , 202 : { bodyMapper : Mappers . GenericResource } , 204 : { bodyMapper : Mappers . GenericResource } , default : { bodyMapper : Mappers . CloudError } } , requestBody : Parameters . parameters4 , queryParameters : [ Parameters . apiVersion1 ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . resourceProviderNamespace , Parameters . parentResourcePath , Parameters . resourceType , Parameters . resourceName ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const getOperationSpec = { path : "/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{parentResourcePath}/{resourceType}/{resourceName}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . GenericResource } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion1 ] , urlParameters : [ Parameters . $host , Parameters . subscriptionId , Parameters . resourceGroupName , Parameters . resourceProviderNamespace , Parameters . parentResourcePath , Parameters . resourceType , Parameters . resourceName ] , headerParameters : [ Parameters . accept ] , serializer } ; const checkExistenceByIdOperationSpec = { path : "/{resourceId}" , httpMethod : "HEAD" , responses : { 204 : { } , 404 : { } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion1 ] , urlParameters : [ Parameters . $host , Parameters . resourceId ] , headerParameters : [ Parameters . accept ] , serializer } ; const deleteByIdOperationSpec = { path : "/{resourceId}" , httpMethod : "DELETE" , responses : { 200 : { } , 201 : { } , 202 : { } , 204 : { } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion1 ] , urlParameters : [ Parameters . $host , Parameters . resourceId ] , headerParameters : [ Parameters . accept ] , serializer } ; const createOrUpdateByIdOperationSpec = { path : "/{resourceId}" , httpMethod : "PUT" , responses : { 200 : { bodyMapper : Mappers . GenericResource } , 201 : { bodyMapper : Mappers . GenericResource } , 202 : { bodyMapper : Mappers . GenericResource } , 204 : { bodyMapper : Mappers . GenericResource } , default : { bodyMapper : Mappers . CloudError } } , requestBody : Parameters . parameters4 , queryParameters : [ Parameters . apiVersion1 ] , urlParameters : [ Parameters . $host , Parameters . resourceId ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const updateByIdOperationSpec = { path : "/{resourceId}" , httpMethod : "PATCH" , responses : { 200 : { bodyMapper : Mappers . GenericResource } , 201 : { bodyMapper : Mappers . GenericResource } , 202 : { bodyMapper : Mappers . GenericResource } , 204 : { bodyMapper : Mappers . GenericResource } , default : { bodyMapper : Mappers . CloudError } } , requestBody : Parameters . parameters4 , queryParameters : [ Parameters . apiVersion1 ] , urlParameters : [ Parameters . $host , Parameters . resourceId ] , headerParameters : [ Parameters . accept , Parameters . contentType ] , mediaType : "json" , serializer } ; const getByIdOperationSpec = { path : "/{resourceId}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . GenericResource } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion1 ] , urlParameters : [ Parameters . $host , Parameters . resourceId ] , headerParameters : [ Parameters . accept ] , serializer } ; const listByResourceGroupNextOperationSpec = { path : "{nextLink}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . ResourceListResult } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion , Parameters . filter , Parameters . top , Parameters . expand ] , urlParameters : [ Parameters . $host , Parameters . nextLink , Parameters . subscriptionId , Parameters . resourceGroupName ] , headerParameters : [ Parameters . accept ] , serializer } ; const listNextOperationSpec = { path : "{nextLink}" , httpMethod : "GET" , responses : { 200 : { bodyMapper : Mappers . ResourceListResult } , default : { bodyMapper : Mappers . CloudError } } , queryParameters : [ Parameters . apiVersion , Parameters . filter , Parameters . top , Parameters . expand ] , urlParameters : [ Parameters . $host , Parameters . nextLink , Parameters . subscriptionId ] , headerParameters : [ Parameters . accept ] , serializer } ;