Skip to content
This repository has been archived by the owner on May 5, 2023. It is now read-only.

Commit

Permalink
[AutoPR sql/resource-manager] Added support for dropped databases on …
Browse files Browse the repository at this point in the history
…Managed Instance (#4486)

* Generated from b69193acc6a531e053151c7ba4aaffb07cb218a0

Added support for dropped databases on Managed Instance

* Generated from 676178334abdb40ac47516783d789272008e8488

Adding support for dropped databases on Managed Instance
  • Loading branch information
AutorestCI authored Jan 18, 2019
1 parent 9e77efd commit 095860a
Show file tree
Hide file tree
Showing 10 changed files with 3,384 additions and 0 deletions.
33 changes: 33 additions & 0 deletions lib/services/sqlManagement2/lib/models/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3118,6 +3118,27 @@ export interface ServerSecurityAlertPolicy extends ProxyResource {
readonly creationTime?: Date;
}

/**
* @class
* Initializes a new instance of the RestorableDroppedManagedDatabase class.
* @constructor
* A restorable dropped managed database resource.
*
* @property {string} [databaseName] The name of the database.
* @property {date} [creationDate] The creation date of the database (ISO8601
* format).
* @property {date} [deletionDate] The deletion date of the database (ISO8601
* format).
* @property {date} [earliestRestoreDate] The earliest restore date of the
* database (ISO8601 format).
*/
export interface RestorableDroppedManagedDatabase extends TrackedResource {
readonly databaseName?: string;
readonly creationDate?: Date;
readonly deletionDate?: Date;
readonly earliestRestoreDate?: Date;
}

/**
* @class
* Initializes a new instance of the RestorePoint class.
Expand Down Expand Up @@ -5037,6 +5058,18 @@ export interface ServerDnsAliasListResult extends Array<ServerDnsAlias> {
readonly nextLink?: string;
}

/**
* @class
* Initializes a new instance of the RestorableDroppedManagedDatabaseListResult class.
* @constructor
* A list of restorable dropped managed databases.
*
* @property {string} [nextLink] Link to retrieve next page of results.
*/
export interface RestorableDroppedManagedDatabaseListResult extends Array<RestorableDroppedManagedDatabase> {
readonly nextLink?: string;
}

/**
* @class
* Initializes a new instance of the RestorePointListResult class.
Expand Down
2 changes: 2 additions & 0 deletions lib/services/sqlManagement2/lib/models/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ exports.ServerAutomaticTuning = require('./serverAutomaticTuning');
exports.ServerDnsAlias = require('./serverDnsAlias');
exports.ServerDnsAliasAcquisition = require('./serverDnsAliasAcquisition');
exports.ServerSecurityAlertPolicy = require('./serverSecurityAlertPolicy');
exports.RestorableDroppedManagedDatabase = require('./restorableDroppedManagedDatabase');
exports.RestorePoint = require('./restorePoint');
exports.CreateDatabaseRestorePointDefinition = require('./createDatabaseRestorePointDefinition');
exports.ManagedDatabaseSecurityAlertPolicy = require('./managedDatabaseSecurityAlertPolicy');
Expand Down Expand Up @@ -212,6 +213,7 @@ exports.LongTermRetentionBackupListResult = require('./longTermRetentionBackupLi
exports.ManagedBackupShortTermRetentionPolicyListResult = require('./managedBackupShortTermRetentionPolicyListResult');
exports.ManagedDatabaseListResult = require('./managedDatabaseListResult');
exports.ServerDnsAliasListResult = require('./serverDnsAliasListResult');
exports.RestorableDroppedManagedDatabaseListResult = require('./restorableDroppedManagedDatabaseListResult');
exports.RestorePointListResult = require('./restorePointListResult');
exports.DatabaseOperationListResult = require('./databaseOperationListResult');
exports.ElasticPoolOperationListResult = require('./elasticPoolOperationListResult');
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,132 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
* regenerated.
*/

'use strict';

const models = require('./index');

/**
* A restorable dropped managed database resource.
*
* @extends models['TrackedResource']
*/
class RestorableDroppedManagedDatabase extends models['TrackedResource'] {
/**
* Create a RestorableDroppedManagedDatabase.
* @property {string} [databaseName] The name of the database.
* @property {date} [creationDate] The creation date of the database (ISO8601
* format).
* @property {date} [deletionDate] The deletion date of the database (ISO8601
* format).
* @property {date} [earliestRestoreDate] The earliest restore date of the
* database (ISO8601 format).
*/
constructor() {
super();
}

/**
* Defines the metadata of RestorableDroppedManagedDatabase
*
* @returns {object} metadata of RestorableDroppedManagedDatabase
*
*/
mapper() {
return {
required: false,
serializedName: 'RestorableDroppedManagedDatabase',
type: {
name: 'Composite',
className: 'RestorableDroppedManagedDatabase',
modelProperties: {
id: {
required: false,
readOnly: true,
serializedName: 'id',
type: {
name: 'String'
}
},
name: {
required: false,
readOnly: true,
serializedName: 'name',
type: {
name: 'String'
}
},
type: {
required: false,
readOnly: true,
serializedName: 'type',
type: {
name: 'String'
}
},
location: {
required: true,
serializedName: 'location',
type: {
name: 'String'
}
},
tags: {
required: false,
serializedName: 'tags',
type: {
name: 'Dictionary',
value: {
required: false,
serializedName: 'StringElementType',
type: {
name: 'String'
}
}
}
},
databaseName: {
required: false,
readOnly: true,
serializedName: 'properties.databaseName',
type: {
name: 'String'
}
},
creationDate: {
required: false,
readOnly: true,
serializedName: 'properties.creationDate',
type: {
name: 'DateTime'
}
},
deletionDate: {
required: false,
readOnly: true,
serializedName: 'properties.deletionDate',
type: {
name: 'DateTime'
}
},
earliestRestoreDate: {
required: false,
readOnly: true,
serializedName: 'properties.earliestRestoreDate',
type: {
name: 'DateTime'
}
}
}
}
};
}
}

module.exports = RestorableDroppedManagedDatabase;
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
/*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for
* license information.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is
* regenerated.
*/

'use strict';

/**
* A list of restorable dropped managed databases.
*/
class RestorableDroppedManagedDatabaseListResult extends Array {
/**
* Create a RestorableDroppedManagedDatabaseListResult.
* @property {string} [nextLink] Link to retrieve next page of results.
*/
constructor() {
super();
}

/**
* Defines the metadata of RestorableDroppedManagedDatabaseListResult
*
* @returns {object} metadata of RestorableDroppedManagedDatabaseListResult
*
*/
mapper() {
return {
required: false,
serializedName: 'RestorableDroppedManagedDatabaseListResult',
type: {
name: 'Composite',
className: 'RestorableDroppedManagedDatabaseListResult',
modelProperties: {
value: {
required: false,
readOnly: true,
serializedName: '',
type: {
name: 'Sequence',
element: {
required: false,
serializedName: 'RestorableDroppedManagedDatabaseElementType',
type: {
name: 'Composite',
className: 'RestorableDroppedManagedDatabase'
}
}
}
},
nextLink: {
required: false,
readOnly: true,
serializedName: 'nextLink',
type: {
name: 'String'
}
}
}
}
};
}
}

module.exports = RestorableDroppedManagedDatabaseListResult;
Loading

0 comments on commit 095860a

Please sign in to comment.