Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR azure-mgmt-resource] Add package-subscriptions-2019-11 #480

Closed
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
Expand Up @@ -28,6 +28,7 @@
from ._models_py3 import ErrorResponse
from ._models_py3 import ExportTemplateRequest
from ._models_py3 import GenericResource
from ._models_py3 import GenericResourceExpanded
from ._models_py3 import GenericResourceFilter
from ._models_py3 import HttpMessage
from ._models_py3 import Identity
Expand Down Expand Up @@ -70,6 +71,7 @@
from ._models import ErrorResponse
from ._models import ExportTemplateRequest
from ._models import GenericResource
from ._models import GenericResourceExpanded
from ._models import GenericResourceFilter
from ._models import HttpMessage
from ._models import Identity
Expand All @@ -95,7 +97,7 @@
from ._models import TemplateLink
from ._paged_models import DeploymentExtendedPaged
from ._paged_models import DeploymentOperationPaged
from ._paged_models import GenericResourcePaged
from ._paged_models import GenericResourceExpandedPaged
from ._paged_models import ProviderPaged
from ._paged_models import ResourceGroupPaged
from ._paged_models import TagDetailsPaged
Expand Down Expand Up @@ -123,6 +125,7 @@
'ErrorResponse',
'ExportTemplateRequest',
'GenericResource',
'GenericResourceExpanded',
'GenericResourceFilter',
'HttpMessage',
'Identity',
Expand All @@ -148,7 +151,7 @@
'TemplateLink',
'DeploymentExtendedPaged',
'ProviderPaged',
'GenericResourcePaged',
'GenericResourceExpandedPaged',
'ResourceGroupPaged',
'TagDetailsPaged',
'DeploymentOperationPaged',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -651,6 +651,78 @@ def __init__(self, **kwargs):
self.identity = kwargs.get('identity', None)


class GenericResourceExpanded(GenericResource):
"""Resource information.

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

:ivar id: Resource Id
:vartype id: str
:ivar name: Resource name
:vartype name: str
:ivar type: Resource type
:vartype type: str
:param location: Resource location
:type location: str
:param tags: Resource tags
:type tags: dict[str, str]
:param plan: The plan of the resource.
:type plan: ~azure.mgmt.resource.resources.v2016_02_01.models.Plan
:param properties: The resource properties.
:type properties: object
:param kind: The kind of the resource.
:type kind: str
:param managed_by: Id of the resource that manages this resource.
:type managed_by: str
:param sku: The sku of the resource.
:type sku: ~azure.mgmt.resource.resources.v2016_02_01.models.Sku
:param identity: The identity of the resource.
:type identity: ~azure.mgmt.resource.resources.v2016_02_01.models.Identity
:ivar created_time: The created time of the resource. This is only present
if requested via the $expand query parameter.
:vartype created_time: datetime
:ivar changed_time: The changed time of the resource. This is only present
if requested via the $expand query parameter.
:vartype changed_time: datetime
:ivar provisioning_state: The provisioning state of the resource. This is
only present if requested via the $expand query parameter.
:vartype provisioning_state: str
"""

_validation = {
'id': {'readonly': True},
'name': {'readonly': True},
'type': {'readonly': True},
'created_time': {'readonly': True},
'changed_time': {'readonly': True},
'provisioning_state': {'readonly': True},
}

_attribute_map = {
'id': {'key': 'id', 'type': 'str'},
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'location': {'key': 'location', 'type': 'str'},
'tags': {'key': 'tags', 'type': '{str}'},
'plan': {'key': 'plan', 'type': 'Plan'},
'properties': {'key': 'properties', 'type': 'object'},
'kind': {'key': 'kind', 'type': 'str'},
'managed_by': {'key': 'managedBy', 'type': 'str'},
'sku': {'key': 'sku', 'type': 'Sku'},
'identity': {'key': 'identity', 'type': 'Identity'},
'created_time': {'key': 'createdTime', 'type': 'iso-8601'},
'changed_time': {'key': 'changedTime', 'type': 'iso-8601'},
'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
}

def __init__(self, **kwargs):
super(GenericResourceExpanded, self).__init__(**kwargs)
self.created_time = None
self.changed_time = None
self.provisioning_state = None


class GenericResourceFilter(Model):
"""Resource filter.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -651,6 +651,78 @@ def __init__(self, *, location: str=None, tags=None, plan=None, properties=None,
self.identity = identity


class GenericResourceExpanded(GenericResource):
"""Resource information.

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

:ivar id: Resource Id
:vartype id: str
:ivar name: Resource name
:vartype name: str
:ivar type: Resource type
:vartype type: str
:param location: Resource location
:type location: str
:param tags: Resource tags
:type tags: dict[str, str]
:param plan: The plan of the resource.
:type plan: ~azure.mgmt.resource.resources.v2016_02_01.models.Plan
:param properties: The resource properties.
:type properties: object
:param kind: The kind of the resource.
:type kind: str
:param managed_by: Id of the resource that manages this resource.
:type managed_by: str
:param sku: The sku of the resource.
:type sku: ~azure.mgmt.resource.resources.v2016_02_01.models.Sku
:param identity: The identity of the resource.
:type identity: ~azure.mgmt.resource.resources.v2016_02_01.models.Identity
:ivar created_time: The created time of the resource. This is only present
if requested via the $expand query parameter.
:vartype created_time: datetime
:ivar changed_time: The changed time of the resource. This is only present
if requested via the $expand query parameter.
:vartype changed_time: datetime
:ivar provisioning_state: The provisioning state of the resource. This is
only present if requested via the $expand query parameter.
:vartype provisioning_state: str
"""

_validation = {
'id': {'readonly': True},
'name': {'readonly': True},
'type': {'readonly': True},
'created_time': {'readonly': True},
'changed_time': {'readonly': True},
'provisioning_state': {'readonly': True},
}

_attribute_map = {
'id': {'key': 'id', 'type': 'str'},
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'location': {'key': 'location', 'type': 'str'},
'tags': {'key': 'tags', 'type': '{str}'},
'plan': {'key': 'plan', 'type': 'Plan'},
'properties': {'key': 'properties', 'type': 'object'},
'kind': {'key': 'kind', 'type': 'str'},
'managed_by': {'key': 'managedBy', 'type': 'str'},
'sku': {'key': 'sku', 'type': 'Sku'},
'identity': {'key': 'identity', 'type': 'Identity'},
'created_time': {'key': 'createdTime', 'type': 'iso-8601'},
'changed_time': {'key': 'changedTime', 'type': 'iso-8601'},
'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
}

def __init__(self, *, location: str=None, tags=None, plan=None, properties=None, kind: str=None, managed_by: str=None, sku=None, identity=None, **kwargs) -> None:
super(GenericResourceExpanded, self).__init__(location=location, tags=tags, plan=plan, properties=properties, kind=kind, managed_by=managed_by, sku=sku, identity=identity, **kwargs)
self.created_time = None
self.changed_time = None
self.provisioning_state = None


class GenericResourceFilter(Model):
"""Resource filter.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,19 +38,19 @@ class ProviderPaged(Paged):
def __init__(self, *args, **kwargs):

super(ProviderPaged, self).__init__(*args, **kwargs)
class GenericResourcePaged(Paged):
class GenericResourceExpandedPaged(Paged):
"""
A paging container for iterating over a list of :class:`GenericResource <azure.mgmt.resource.resources.v2016_02_01.models.GenericResource>` object
A paging container for iterating over a list of :class:`GenericResourceExpanded <azure.mgmt.resource.resources.v2016_02_01.models.GenericResourceExpanded>` object
"""

_attribute_map = {
'next_link': {'key': 'nextLink', 'type': 'str'},
'current_page': {'key': 'value', 'type': '[GenericResource]'}
'current_page': {'key': 'value', 'type': '[GenericResourceExpanded]'}
}

def __init__(self, *args, **kwargs):

super(GenericResourcePaged, self).__init__(*args, **kwargs)
super(GenericResourceExpandedPaged, self).__init__(*args, **kwargs)
class ResourceGroupPaged(Paged):
"""
A paging container for iterating over a list of :class:`ResourceGroup <azure.mgmt.resource.resources.v2016_02_01.models.ResourceGroup>` object
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,10 @@ def list_resources(
:type resource_group_name: str
:param filter: The filter to apply on the operation.
:type filter: str
:param expand: The $expand query parameter
:param expand: Comma-separated list of additional properties to be
included in the response. Valid values include `createdTime`,
`changedTime` and `provisioningState`. For example,
`$expand=createdTime,changedTime`.
:type expand: str
:param top: Query parameters. If null is passed returns all resource
groups.
Expand All @@ -60,9 +63,9 @@ def list_resources(
deserialized response
:param operation_config: :ref:`Operation configuration
overrides<msrest:optionsforoperations>`.
:return: An iterator like instance of GenericResource
:return: An iterator like instance of GenericResourceExpanded
:rtype:
~azure.mgmt.resource.resources.v2016_02_01.models.GenericResourcePaged[~azure.mgmt.resource.resources.v2016_02_01.models.GenericResource]
~azure.mgmt.resource.resources.v2016_02_01.models.GenericResourceExpandedPaged[~azure.mgmt.resource.resources.v2016_02_01.models.GenericResourceExpanded]
:raises: :class:`CloudError<msrestazure.azure_exceptions.CloudError>`
"""
def prepare_request(next_link=None):
Expand Down Expand Up @@ -119,7 +122,7 @@ def internal_paging(next_link=None):
header_dict = None
if raw:
header_dict = {}
deserialized = models.GenericResourcePaged(internal_paging, self._deserialize.dependencies, header_dict)
deserialized = models.GenericResourceExpandedPaged(internal_paging, self._deserialize.dependencies, header_dict)

return deserialized
list_resources.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/resources'}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,10 @@ def list(

:param filter: The filter to apply on the operation.
:type filter: str
:param expand: The $expand query parameter.
:param expand: Comma-separated list of additional properties to be
included in the response. Valid values include `createdTime`,
`changedTime` and `provisioningState`. For example,
`$expand=createdTime,changedTime`.
:type expand: str
:param top: Query parameters. If null is passed returns all resource
groups.
Expand All @@ -145,9 +148,9 @@ def list(
deserialized response
:param operation_config: :ref:`Operation configuration
overrides<msrest:optionsforoperations>`.
:return: An iterator like instance of GenericResource
:return: An iterator like instance of GenericResourceExpanded
:rtype:
~azure.mgmt.resource.resources.v2016_02_01.models.GenericResourcePaged[~azure.mgmt.resource.resources.v2016_02_01.models.GenericResource]
~azure.mgmt.resource.resources.v2016_02_01.models.GenericResourceExpandedPaged[~azure.mgmt.resource.resources.v2016_02_01.models.GenericResourceExpanded]
:raises: :class:`CloudError<msrestazure.azure_exceptions.CloudError>`
"""
def prepare_request(next_link=None):
Expand Down Expand Up @@ -203,7 +206,7 @@ def internal_paging(next_link=None):
header_dict = None
if raw:
header_dict = {}
deserialized = models.GenericResourcePaged(internal_paging, self._deserialize.dependencies, header_dict)
deserialized = models.GenericResourceExpandedPaged(internal_paging, self._deserialize.dependencies, header_dict)

return deserialized
list.metadata = {'url': '/subscriptions/{subscriptionId}/resources'}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
from ._models_py3 import ErrorResponse
from ._models_py3 import ExportTemplateRequest
from ._models_py3 import GenericResource
from ._models_py3 import GenericResourceExpanded
from ._models_py3 import GenericResourceFilter
from ._models_py3 import HttpMessage
from ._models_py3 import Identity
Expand Down Expand Up @@ -70,6 +71,7 @@
from ._models import ErrorResponse
from ._models import ExportTemplateRequest
from ._models import GenericResource
from ._models import GenericResourceExpanded
from ._models import GenericResourceFilter
from ._models import HttpMessage
from ._models import Identity
Expand All @@ -95,7 +97,7 @@
from ._models import TemplateLink
from ._paged_models import DeploymentExtendedPaged
from ._paged_models import DeploymentOperationPaged
from ._paged_models import GenericResourcePaged
from ._paged_models import GenericResourceExpandedPaged
from ._paged_models import ProviderPaged
from ._paged_models import ResourceGroupPaged
from ._paged_models import TagDetailsPaged
Expand Down Expand Up @@ -123,6 +125,7 @@
'ErrorResponse',
'ExportTemplateRequest',
'GenericResource',
'GenericResourceExpanded',
'GenericResourceFilter',
'HttpMessage',
'Identity',
Expand All @@ -148,7 +151,7 @@
'TemplateLink',
'DeploymentExtendedPaged',
'ProviderPaged',
'GenericResourcePaged',
'GenericResourceExpandedPaged',
'ResourceGroupPaged',
'TagDetailsPaged',
'DeploymentOperationPaged',
Expand Down
Loading