Skip to content
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
12 changes: 9 additions & 3 deletions azure-mgmt-storagesync/azure/mgmt/storagesync/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@
from .storage_sync_error_details_py3 import StorageSyncErrorDetails
from .storage_sync_error_py3 import StorageSyncError, StorageSyncErrorException
from .resource_py3 import Resource
from .tracked_resource_py3 import TrackedResource
from .subscription_state_py3 import SubscriptionState
from .storage_sync_service_py3 import StorageSyncService
from .sync_group_py3 import SyncGroup
from .cloud_endpoint_py3 import CloudEndpoint
from .server_endpoint_update_parameters_py3 import ServerEndpointUpdateParameters
from .server_endpoint_py3 import ServerEndpoint
from .registered_server_py3 import RegisteredServer
from .resources_move_info_py3 import ResourcesMoveInfo
Expand All @@ -33,15 +33,17 @@
from .backup_request_py3 import BackupRequest
from .post_backup_response_py3 import PostBackupResponse
from .workflow_array_py3 import WorkflowArray
from .storage_sync_service_update_parameters_py3 import StorageSyncServiceUpdateParameters
from .tracked_resource_py3 import TrackedResource
except (SyntaxError, ImportError):
from .storage_sync_error_details import StorageSyncErrorDetails
from .storage_sync_error import StorageSyncError, StorageSyncErrorException
from .resource import Resource
from .tracked_resource import TrackedResource
from .subscription_state import SubscriptionState
from .storage_sync_service import StorageSyncService
from .sync_group import SyncGroup
from .cloud_endpoint import CloudEndpoint
from .server_endpoint_update_parameters import ServerEndpointUpdateParameters
from .server_endpoint import ServerEndpoint
from .registered_server import RegisteredServer
from .resources_move_info import ResourcesMoveInfo
Expand All @@ -57,6 +59,8 @@
from .backup_request import BackupRequest
from .post_backup_response import PostBackupResponse
from .workflow_array import WorkflowArray
from .storage_sync_service_update_parameters import StorageSyncServiceUpdateParameters
from .tracked_resource import TrackedResource
from .operation_entity_paged import OperationEntityPaged
from .storage_sync_service_paged import StorageSyncServicePaged
from .sync_group_paged import SyncGroupPaged
Expand All @@ -72,11 +76,11 @@
'StorageSyncErrorDetails',
'StorageSyncError', 'StorageSyncErrorException',
'Resource',
'TrackedResource',
'SubscriptionState',
'StorageSyncService',
'SyncGroup',
'CloudEndpoint',
'ServerEndpointUpdateParameters',
'ServerEndpoint',
'RegisteredServer',
'ResourcesMoveInfo',
Expand All @@ -92,6 +96,8 @@
'BackupRequest',
'PostBackupResponse',
'WorkflowArray',
'StorageSyncServiceUpdateParameters',
'TrackedResource',
'OperationEntityPaged',
'StorageSyncServicePaged',
'SyncGroupPaged',
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# coding=utf-8
# --------------------------------------------------------------------------
# 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.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class ServerEndpointUpdateParameters(Model):
"""Parameters for updating an Server Endpoint.

:param tags: The user-specified tags associated with the server endpoint.
:type tags: dict[str, str]
:param cloud_tiering: Cloud Tiering. Possible values include: 'on', 'off'
:type cloud_tiering: str or ~azure.mgmt.storagesync.models.enum
:param volume_free_space_percent: Level of free space to be maintained by
Cloud Tiering if it is enabled.
:type volume_free_space_percent: int
"""

_validation = {
'volume_free_space_percent': {'maximum': 100, 'minimum': 0},
}

_attribute_map = {
'tags': {'key': 'tags', 'type': '{str}'},
'cloud_tiering': {'key': 'properties.cloudTiering', 'type': 'str'},
'volume_free_space_percent': {'key': 'properties.volumeFreeSpacePercent', 'type': 'int'},
}

def __init__(self, **kwargs):
super(ServerEndpointUpdateParameters, self).__init__(**kwargs)
self.tags = kwargs.get('tags', None)
self.cloud_tiering = kwargs.get('cloud_tiering', None)
self.volume_free_space_percent = kwargs.get('volume_free_space_percent', None)
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# coding=utf-8
# --------------------------------------------------------------------------
# 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.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class ServerEndpointUpdateParameters(Model):
"""Parameters for updating an Server Endpoint.

:param tags: The user-specified tags associated with the server endpoint.
:type tags: dict[str, str]
:param cloud_tiering: Cloud Tiering. Possible values include: 'on', 'off'
:type cloud_tiering: str or ~azure.mgmt.storagesync.models.enum
:param volume_free_space_percent: Level of free space to be maintained by
Cloud Tiering if it is enabled.
:type volume_free_space_percent: int
"""

_validation = {
'volume_free_space_percent': {'maximum': 100, 'minimum': 0},
}

_attribute_map = {
'tags': {'key': 'tags', 'type': '{str}'},
'cloud_tiering': {'key': 'properties.cloudTiering', 'type': 'str'},
'volume_free_space_percent': {'key': 'properties.volumeFreeSpacePercent', 'type': 'int'},
}

def __init__(self, *, tags=None, cloud_tiering=None, volume_free_space_percent: int=None, **kwargs) -> None:
super(ServerEndpointUpdateParameters, self).__init__(**kwargs)
self.tags = tags
self.cloud_tiering = cloud_tiering
self.volume_free_space_percent = volume_free_space_percent
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,18 @@ class StorageSyncService(TrackedResource):
Variables are only populated by the server, and will be ignored when
sending a request.

All required parameters must be populated in order to send to Azure.

:ivar id: The id of the resource.
:vartype id: str
:ivar name: The name of the resource.
:vartype name: str
:ivar type: The type of the resource
:vartype type: str
:param location: The location of the resource.
:param tags: Resource tags.
:type tags: dict[str, str]
:param location: Required. The geo-location where the resource lives
:type location: str
:param tags: The tags of the resource.
:type tags: object
:ivar storage_sync_service_status: Storage Sync service status.
:vartype storage_sync_service_status: int
:ivar storage_sync_service_uid: Storage Sync service Uid
Expand All @@ -38,6 +40,7 @@ class StorageSyncService(TrackedResource):
'id': {'readonly': True},
'name': {'readonly': True},
'type': {'readonly': True},
'location': {'required': True},
'storage_sync_service_status': {'readonly': True},
'storage_sync_service_uid': {'readonly': True},
}
Expand All @@ -46,8 +49,8 @@ class StorageSyncService(TrackedResource):
'id': {'key': 'id', 'type': 'str'},
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'tags': {'key': 'tags', 'type': '{str}'},
'location': {'key': 'location', 'type': 'str'},
'tags': {'key': 'tags', 'type': 'object'},
'storage_sync_service_status': {'key': 'properties.storageSyncServiceStatus', 'type': 'int'},
'storage_sync_service_uid': {'key': 'properties.storageSyncServiceUid', 'type': 'str'},
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,16 +18,18 @@ class StorageSyncService(TrackedResource):
Variables are only populated by the server, and will be ignored when
sending a request.

All required parameters must be populated in order to send to Azure.

:ivar id: The id of the resource.
:vartype id: str
:ivar name: The name of the resource.
:vartype name: str
:ivar type: The type of the resource
:vartype type: str
:param location: The location of the resource.
:param tags: Resource tags.
:type tags: dict[str, str]
:param location: Required. The geo-location where the resource lives
:type location: str
:param tags: The tags of the resource.
:type tags: object
:ivar storage_sync_service_status: Storage Sync service status.
:vartype storage_sync_service_status: int
:ivar storage_sync_service_uid: Storage Sync service Uid
Expand All @@ -38,6 +40,7 @@ class StorageSyncService(TrackedResource):
'id': {'readonly': True},
'name': {'readonly': True},
'type': {'readonly': True},
'location': {'required': True},
'storage_sync_service_status': {'readonly': True},
'storage_sync_service_uid': {'readonly': True},
}
Expand All @@ -46,13 +49,13 @@ class StorageSyncService(TrackedResource):
'id': {'key': 'id', 'type': 'str'},
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'tags': {'key': 'tags', 'type': '{str}'},
'location': {'key': 'location', 'type': 'str'},
'tags': {'key': 'tags', 'type': 'object'},
'storage_sync_service_status': {'key': 'properties.storageSyncServiceStatus', 'type': 'int'},
'storage_sync_service_uid': {'key': 'properties.storageSyncServiceUid', 'type': 'str'},
}

def __init__(self, *, location: str=None, tags=None, **kwargs) -> None:
super(StorageSyncService, self).__init__(location=location, tags=tags, **kwargs)
def __init__(self, *, location: str, tags=None, **kwargs) -> None:
super(StorageSyncService, self).__init__(tags=tags, location=location, **kwargs)
self.storage_sync_service_status = None
self.storage_sync_service_uid = None
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# coding=utf-8
# --------------------------------------------------------------------------
# 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.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class StorageSyncServiceUpdateParameters(Model):
"""Parameters for updating an Storage sync service.

:param tags: The user-specified tags associated with the storage sync
service.
:type tags: dict[str, str]
:param properties: The properties of the storage sync service.
:type properties: object
"""

_attribute_map = {
'tags': {'key': 'tags', 'type': '{str}'},
'properties': {'key': 'properties', 'type': 'object'},
}

def __init__(self, **kwargs):
super(StorageSyncServiceUpdateParameters, self).__init__(**kwargs)
self.tags = kwargs.get('tags', None)
self.properties = kwargs.get('properties', None)
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# coding=utf-8
# --------------------------------------------------------------------------
# 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.
# --------------------------------------------------------------------------

from msrest.serialization import Model


class StorageSyncServiceUpdateParameters(Model):
"""Parameters for updating an Storage sync service.

:param tags: The user-specified tags associated with the storage sync
service.
:type tags: dict[str, str]
:param properties: The properties of the storage sync service.
:type properties: object
"""

_attribute_map = {
'tags': {'key': 'tags', 'type': '{str}'},
'properties': {'key': 'properties', 'type': 'object'},
}

def __init__(self, *, tags=None, properties=None, **kwargs) -> None:
super(StorageSyncServiceUpdateParameters, self).__init__(**kwargs)
self.tags = tags
self.properties = properties
Original file line number Diff line number Diff line change
Expand Up @@ -13,38 +13,41 @@


class TrackedResource(Resource):
"""ARM tracked resource.
"""The resource model definition for a ARM tracked top level resource.

Variables are only populated by the server, and will be ignored when
sending a request.

All required parameters must be populated in order to send to Azure.

:ivar id: The id of the resource.
:vartype id: str
:ivar name: The name of the resource.
:vartype name: str
:ivar type: The type of the resource
:vartype type: str
:param location: The location of the resource.
:param tags: Resource tags.
:type tags: dict[str, str]
:param location: Required. The geo-location where the resource lives
:type location: str
:param tags: The tags of the resource.
:type tags: object
"""

_validation = {
'id': {'readonly': True},
'name': {'readonly': True},
'type': {'readonly': True},
'location': {'required': True},
}

_attribute_map = {
'id': {'key': 'id', 'type': 'str'},
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'tags': {'key': 'tags', 'type': '{str}'},
'location': {'key': 'location', 'type': 'str'},
'tags': {'key': 'tags', 'type': 'object'},
}

def __init__(self, **kwargs):
super(TrackedResource, self).__init__(**kwargs)
self.location = kwargs.get('location', None)
self.tags = kwargs.get('tags', None)
self.location = kwargs.get('location', None)
Original file line number Diff line number Diff line change
Expand Up @@ -13,38 +13,41 @@


class TrackedResource(Resource):
"""ARM tracked resource.
"""The resource model definition for a ARM tracked top level resource.

Variables are only populated by the server, and will be ignored when
sending a request.

All required parameters must be populated in order to send to Azure.

:ivar id: The id of the resource.
:vartype id: str
:ivar name: The name of the resource.
:vartype name: str
:ivar type: The type of the resource
:vartype type: str
:param location: The location of the resource.
:param tags: Resource tags.
:type tags: dict[str, str]
:param location: Required. The geo-location where the resource lives
:type location: str
:param tags: The tags of the resource.
:type tags: object
"""

_validation = {
'id': {'readonly': True},
'name': {'readonly': True},
'type': {'readonly': True},
'location': {'required': True},
}

_attribute_map = {
'id': {'key': 'id', 'type': 'str'},
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'tags': {'key': 'tags', 'type': '{str}'},
'location': {'key': 'location', 'type': 'str'},
'tags': {'key': 'tags', 'type': 'object'},
}

def __init__(self, *, location: str=None, tags=None, **kwargs) -> None:
def __init__(self, *, location: str, tags=None, **kwargs) -> None:
super(TrackedResource, self).__init__(**kwargs)
self.location = location
self.tags = tags
self.location = location
Loading