diff --git a/sdk/compute/arm-compute/src/models/index.ts b/sdk/compute/arm-compute/src/models/index.ts index cc59586f553f..daaa1efab0e5 100644 --- a/sdk/compute/arm-compute/src/models/index.ts +++ b/sdk/compute/arm-compute/src/models/index.ts @@ -6590,6 +6590,16 @@ export interface VirtualMachineImagesListOptionalParams extends msRest.RequestOp orderby?: string; } +/** + * Optional Parameters. + */ +export interface VirtualMachinesDeleteMethodOptionalParams extends msRest.RequestOptionsBase { + /** + * Optional parameter to force delete virtual machines. + */ + forceDeletion?: boolean; +} + /** * Optional Parameters. */ @@ -6644,6 +6654,16 @@ export interface VirtualMachinesRetrieveBootDiagnosticsDataOptionalParams extend sasUriExpirationTimeInMinutes?: number; } +/** + * Optional Parameters. + */ +export interface VirtualMachinesBeginDeleteMethodOptionalParams extends msRest.RequestOptionsBase { + /** + * Optional parameter to force delete virtual machines. + */ + forceDeletion?: boolean; +} + /** * Optional Parameters. */ diff --git a/sdk/compute/arm-compute/src/models/parameters.ts b/sdk/compute/arm-compute/src/models/parameters.ts index 30115323b65c..44481e5da48f 100644 --- a/sdk/compute/arm-compute/src/models/parameters.ts +++ b/sdk/compute/arm-compute/src/models/parameters.ts @@ -179,6 +179,18 @@ export const filter: msRest.OperationQueryParameter = { } } }; +export const forceDeletion: msRest.OperationQueryParameter = { + parameterPath: [ + "options", + "forceDeletion" + ], + mapper: { + serializedName: "forceDeletion", + type: { + name: "Boolean" + } + } +}; export const galleryApplicationName: msRest.OperationURLParameter = { parameterPath: "galleryApplicationName", mapper: { diff --git a/sdk/compute/arm-compute/src/operations/virtualMachines.ts b/sdk/compute/arm-compute/src/operations/virtualMachines.ts index ce51df188f82..3ccec79f95c2 100644 --- a/sdk/compute/arm-compute/src/operations/virtualMachines.ts +++ b/sdk/compute/arm-compute/src/operations/virtualMachines.ts @@ -103,7 +103,7 @@ export class VirtualMachines { * @param [options] The optional parameters * @returns Promise */ - deleteMethod(resourceGroupName: string, vmName: string, options?: msRest.RequestOptionsBase): Promise { + deleteMethod(resourceGroupName: string, vmName: string, options?: Models.VirtualMachinesDeleteMethodOptionalParams): Promise { return this.beginDeleteMethod(resourceGroupName,vmName,options) .then(lroPoller => lroPoller.pollUntilFinished()); } @@ -564,7 +564,7 @@ export class VirtualMachines { * @param [options] The optional parameters * @returns Promise */ - beginDeleteMethod(resourceGroupName: string, vmName: string, options?: msRest.RequestOptionsBase): Promise { + beginDeleteMethod(resourceGroupName: string, vmName: string, options?: Models.VirtualMachinesBeginDeleteMethodOptionalParams): Promise { return this.client.sendLRORequest( { resourceGroupName, @@ -1199,6 +1199,7 @@ const beginDeleteMethodOperationSpec: msRest.OperationSpec = { Parameters.subscriptionId ], queryParameters: [ + Parameters.forceDeletion, Parameters.apiVersion0 ], headerParameters: [