Skip to content
This repository was archived by the owner on May 5, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
/*
* 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');

/**
* The resource model definition for a Azure Resource Manager resource with an
* etag.
*
* @extends models['Resource']
*/
class AzureEntityResource extends models['Resource'] {
/**
* Create a AzureEntityResource.
* @member {string} [etag] Resource Etag.
*/
constructor() {
super();
}

/**
* Defines the metadata of AzureEntityResource
*
* @returns {object} metadata of AzureEntityResource
*
*/
mapper() {
return {
required: false,
serializedName: 'AzureEntityResource',
type: {
name: 'Composite',
className: 'AzureEntityResource',
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'
}
},
etag: {
required: false,
readOnly: true,
serializedName: 'etag',
type: {
name: 'String'
}
}
}
}
};
}
}

module.exports = AzureEntityResource;
28 changes: 26 additions & 2 deletions lib/services/storagesyncManagement/lib/models/cloudEndpoint.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ const models = require('./index');
/**
* Cloud Endpoint object.
*
* @extends models['BaseResource']
* @extends models['Resource']
*/
class CloudEndpoint extends models['BaseResource'] {
class CloudEndpoint extends models['Resource'] {
/**
* Create a CloudEndpoint.
* @member {string} [storageAccountKey] Storage Account access key.
Expand Down Expand Up @@ -50,6 +50,30 @@ class CloudEndpoint extends models['BaseResource'] {
name: 'Composite',
className: 'CloudEndpoint',
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'
}
},
storageAccountKey: {
required: false,
serializedName: 'properties.storageAccountKey',
Expand Down
78 changes: 51 additions & 27 deletions lib/services/storagesyncManagement/lib/models/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,13 +53,30 @@ export interface StorageSyncError {

/**
* @class
* Initializes a new instance of the Resource class.
* Initializes a new instance of the SubscriptionState class.
* @constructor
* The Azure Resource Manager resource.
* Subscription State object.
*
* @member {string} [id] The id of the resource.
* @member {string} [name] The name of the resource.
* @member {string} [type] The type of the resource
* @member {string} [state] State of Azure Subscription. Possible values
* include: 'Registered', 'Unregistered', 'Warned', 'Suspended', 'Deleted'
* @member {boolean} [istransitioning] Is Transitioning
* @member {object} [properties] Subscription state properties.
*/
export interface SubscriptionState {
state?: string;
readonly istransitioning?: boolean;
properties?: any;
}

/**
* @class
* Initializes a new instance of the Resource class.
* @constructor
* @member {string} [id] Fully qualified resource Id for the resource. Ex -
* /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
* @member {string} [name] The name of the resource
* @member {string} [type] The type of the resource. Ex-
* Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts.
*/
export interface Resource extends BaseResource {
readonly id?: string;
Expand All @@ -69,19 +86,16 @@ export interface Resource extends BaseResource {

/**
* @class
* Initializes a new instance of the SubscriptionState class.
* Initializes a new instance of the TrackedResource class.
* @constructor
* Subscription State object.
* The resource model definition for a ARM tracked top level resource
*
* @member {string} [state] State of Azure Subscription. Possible values
* include: 'Registered', 'Unregistered', 'Warned', 'Suspended', 'Deleted'
* @member {boolean} [istransitioning] Is Transitioning
* @member {object} [properties] Subscription state properties.
* @member {object} [tags] Resource tags.
* @member {string} location The geo-location where the resource lives
*/
export interface SubscriptionState {
state?: string;
readonly istransitioning?: boolean;
properties?: any;
export interface TrackedResource extends Resource {
tags?: { [propertyName: string]: string };
location: string;
}

/**
Expand All @@ -93,7 +107,7 @@ export interface SubscriptionState {
* @member {number} [storageSyncServiceStatus] Storage Sync service status.
* @member {string} [storageSyncServiceUid] Storage Sync service Uid
*/
export interface StorageSyncService extends BaseResource {
export interface StorageSyncService extends TrackedResource {
readonly storageSyncServiceStatus?: number;
readonly storageSyncServiceUid?: string;
}
Expand All @@ -107,7 +121,7 @@ export interface StorageSyncService extends BaseResource {
* @member {string} [uniqueId] Unique Id
* @member {string} [syncGroupStatus] Sync group status
*/
export interface SyncGroup extends BaseResource {
export interface SyncGroup extends Resource {
uniqueId?: string;
readonly syncGroupStatus?: string;
}
Expand All @@ -130,7 +144,7 @@ export interface SyncGroup extends BaseResource {
* @member {string} [lastWorkflowId] CloudEndpoint lastWorkflowId
* @member {string} [lastOperationName] Resource Last Operation Name
*/
export interface CloudEndpoint extends BaseResource {
export interface CloudEndpoint extends Resource {
storageAccountKey?: string;
storageAccount?: string;
storageAccountResourceId?: string;
Expand Down Expand Up @@ -181,7 +195,7 @@ export interface ServerEndpointUpdateParameters {
* @member {string} [lastOperationName] Resource Last Operation Name
* @member {object} [syncStatus] Sync Health Status
*/
export interface ServerEndpoint extends BaseResource {
export interface ServerEndpoint extends Resource {
serverLocalPath?: string;
cloudTiering?: string;
volumeFreeSpacePercent?: number;
Expand Down Expand Up @@ -275,7 +289,7 @@ export interface ResourcesMoveInfo {
* @member {string} [steps] workflow steps
* @member {string} [lastOperationId] workflow last operation identifier.
*/
export interface Workflow extends BaseResource {
export interface Workflow extends Resource {
lastStepName?: string;
status?: string;
operation?: string;
Expand Down Expand Up @@ -501,16 +515,26 @@ export interface StorageSyncServiceUpdateParameters {

/**
* @class
* Initializes a new instance of the TrackedResource class.
* Initializes a new instance of the ProxyResource class.
* @constructor
* The resource model definition for a ARM tracked top level resource
* The resource model definition for a ARM proxy resource. It will have
* everything other than required location and tags
*
* @member {object} [tags] Resource tags.
* @member {string} location The geo-location where the resource lives
*/
export interface TrackedResource extends Resource {
tags?: { [propertyName: string]: string };
location: string;
export interface ProxyResource extends Resource {
}

/**
* @class
* Initializes a new instance of the AzureEntityResource class.
* @constructor
* The resource model definition for a Azure Resource Manager resource with an
* etag.
*
* @member {string} [etag] Resource Etag.
*/
export interface AzureEntityResource extends Resource {
readonly etag?: string;
}


Expand Down
6 changes: 4 additions & 2 deletions lib/services/storagesyncManagement/lib/models/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,9 @@ exports.BaseResource = msRestAzure.BaseResource;
exports.CloudError = msRestAzure.CloudError;
exports.StorageSyncErrorDetails = require('./storageSyncErrorDetails');
exports.StorageSyncError = require('./storageSyncError');
exports.Resource = require('./resource');
exports.SubscriptionState = require('./subscriptionState');
exports.Resource = require('./resource');
exports.TrackedResource = require('./trackedResource');
exports.StorageSyncService = require('./storageSyncService');
exports.SyncGroup = require('./syncGroup');
exports.CloudEndpoint = require('./cloudEndpoint');
Expand All @@ -42,7 +43,8 @@ exports.BackupRequest = require('./backupRequest');
exports.PostBackupResponse = require('./postBackupResponse');
exports.WorkflowArray = require('./workflowArray');
exports.StorageSyncServiceUpdateParameters = require('./storageSyncServiceUpdateParameters');
exports.TrackedResource = require('./trackedResource');
exports.ProxyResource = require('./proxyResource');
exports.AzureEntityResource = require('./azureEntityResource');
exports.OperationEntityListResult = require('./operationEntityListResult');
exports.StorageSyncServiceArray = require('./storageSyncServiceArray');
exports.SyncGroupArray = require('./syncGroupArray');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@

'use strict';

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

/**
* The operation supported by storage sync.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@

'use strict';

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

/**
* Post Restore Request
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@

'use strict';

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

/**
* Pre Restore request object.
*
Expand Down
73 changes: 73 additions & 0 deletions lib/services/storagesyncManagement/lib/models/proxyResource.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
/*
* 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');

/**
* The resource model definition for a ARM proxy resource. It will have
* everything other than required location and tags
*
* @extends models['Resource']
*/
class ProxyResource extends models['Resource'] {
/**
* Create a ProxyResource.
*/
constructor() {
super();
}

/**
* Defines the metadata of ProxyResource
*
* @returns {object} metadata of ProxyResource
*
*/
mapper() {
return {
required: false,
serializedName: 'ProxyResource',
type: {
name: 'Composite',
className: 'ProxyResource',
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'
}
}
}
}
};
}
}

module.exports = ProxyResource;
Loading