diff --git a/src/quantum/azext_quantum/operations/workspace.py b/src/quantum/azext_quantum/operations/workspace.py index d505b6bcc7c..e295cfcf784 100644 --- a/src/quantum/azext_quantum/operations/workspace.py +++ b/src/quantum/azext_quantum/operations/workspace.py @@ -79,7 +79,7 @@ def create(cmd, resource_group_name=None, workspace_name=None, location=None, st if (not info.resource_group): raise CLIError("Please run 'az quantum workspace set' first to select a default Quantum Workspace.") quantum_workspace = get_basic_quantum_workspace(location, info, storage_account) - return client.create_and_update(info.resource_group, info.name, quantum_workspace, polling=False) + return client.create_or_update(info.resource_group, info.name, quantum_workspace, polling=False) def delete(cmd, resource_group_name=None, workspace_name=None): diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/__init__.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/__init__.py index a21ee3f9853..dd67ed6ff1b 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/__init__.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/__init__.py @@ -12,33 +12,40 @@ try: from .error_definition_py3 import ErrorDefinition from .error_response_py3 import ErrorResponse, ErrorResponseException + from .provider_py3 import Provider from .quantum_workspace_identity_py3 import QuantumWorkspaceIdentity from .quantum_workspace_py3 import QuantumWorkspace - from .provider_description_properties_py3 import ProviderDescriptionProperties - from .provider_description_py3 import ProviderDescription - from .provider_py3 import Provider - from .workspace_resource_properties_py3 import WorkspaceResourceProperties from .provider_properties_aad_py3 import ProviderPropertiesAad from .provider_properties_managed_application_py3 import ProviderPropertiesManagedApplication from .target_description_py3 import TargetDescription + from .quota_dimension_py3 import QuotaDimension + from .pricing_detail_py3 import PricingDetail from .sku_description_py3 import SkuDescription + from .pricing_dimension_py3 import PricingDimension from .provider_properties_py3 import ProviderProperties + from .provider_description_py3 import ProviderDescription + from .operation_display_py3 import OperationDisplay + from .operation_py3 import Operation except (SyntaxError, ImportError): from .error_definition import ErrorDefinition from .error_response import ErrorResponse, ErrorResponseException + from .provider import Provider from .quantum_workspace_identity import QuantumWorkspaceIdentity from .quantum_workspace import QuantumWorkspace - from .provider_description_properties import ProviderDescriptionProperties - from .provider_description import ProviderDescription - from .provider import Provider - from .workspace_resource_properties import WorkspaceResourceProperties from .provider_properties_aad import ProviderPropertiesAad from .provider_properties_managed_application import ProviderPropertiesManagedApplication from .target_description import TargetDescription + from .quota_dimension import QuotaDimension + from .pricing_detail import PricingDetail from .sku_description import SkuDescription + from .pricing_dimension import PricingDimension from .provider_properties import ProviderProperties + from .provider_description import ProviderDescription + from .operation_display import OperationDisplay + from .operation import Operation from .quantum_workspace_paged import QuantumWorkspacePaged from .provider_description_paged import ProviderDescriptionPaged +from .operation_paged import OperationPaged from .quantum_management_client_enums import ( Status, UsableStatus, @@ -48,19 +55,23 @@ __all__ = [ 'ErrorDefinition', 'ErrorResponse', 'ErrorResponseException', + 'Provider', 'QuantumWorkspaceIdentity', 'QuantumWorkspace', - 'ProviderDescriptionProperties', - 'ProviderDescription', - 'Provider', - 'WorkspaceResourceProperties', 'ProviderPropertiesAad', 'ProviderPropertiesManagedApplication', 'TargetDescription', + 'QuotaDimension', + 'PricingDetail', 'SkuDescription', + 'PricingDimension', 'ProviderProperties', + 'ProviderDescription', + 'OperationDisplay', + 'Operation', 'QuantumWorkspacePaged', 'ProviderDescriptionPaged', + 'OperationPaged', 'Status', 'UsableStatus', 'ProvisioningStatus', diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation.py new file mode 100644 index 00000000000..3b819000717 --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation.py @@ -0,0 +1,32 @@ +# 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 Operation(Model): + """Operation provided by provider. + + :param name: Name of the operation + :type name: str + :param display: Properties of the operation + :type display: ~quantum.models.OperationDisplay + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'display': {'key': 'display', 'type': 'OperationDisplay'}, + } + + def __init__(self, **kwargs): + super(Operation, self).__init__(**kwargs) + self.name = kwargs.get('name', None) + self.display = kwargs.get('display', None) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_display.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_display.py new file mode 100644 index 00000000000..89c4bdd6ccb --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_display.py @@ -0,0 +1,40 @@ +# 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 OperationDisplay(Model): + """Properties of the operation. + + :param provider: Provider name + :type provider: str + :param resource: Resource name + :type resource: str + :param operation: Operation name + :type operation: str + :param description: Description of the operation + :type description: str + """ + + _attribute_map = { + 'provider': {'key': 'provider', 'type': 'str'}, + 'resource': {'key': 'resource', 'type': 'str'}, + 'operation': {'key': 'operation', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(OperationDisplay, self).__init__(**kwargs) + self.provider = kwargs.get('provider', None) + self.resource = kwargs.get('resource', None) + self.operation = kwargs.get('operation', None) + self.description = kwargs.get('description', None) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_display_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_display_py3.py new file mode 100644 index 00000000000..fa3740dfc65 --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_display_py3.py @@ -0,0 +1,40 @@ +# 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 OperationDisplay(Model): + """Properties of the operation. + + :param provider: Provider name + :type provider: str + :param resource: Resource name + :type resource: str + :param operation: Operation name + :type operation: str + :param description: Description of the operation + :type description: str + """ + + _attribute_map = { + 'provider': {'key': 'provider', 'type': 'str'}, + 'resource': {'key': 'resource', 'type': 'str'}, + 'operation': {'key': 'operation', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + } + + def __init__(self, *, provider: str=None, resource: str=None, operation: str=None, description: str=None, **kwargs) -> None: + super(OperationDisplay, self).__init__(**kwargs) + self.provider = provider + self.resource = resource + self.operation = operation + self.description = description diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_paged.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_paged.py new file mode 100644 index 00000000000..60371a7b0d3 --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_paged.py @@ -0,0 +1,27 @@ +# 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.paging import Paged + + +class OperationPaged(Paged): + """ + A paging container for iterating over a list of :class:`Operation ` object + """ + + _attribute_map = { + 'next_link': {'key': 'nextLink', 'type': 'str'}, + 'current_page': {'key': 'value', 'type': '[Operation]'} + } + + def __init__(self, *args, **kwargs): + + super(OperationPaged, self).__init__(*args, **kwargs) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_py3.py new file mode 100644 index 00000000000..1cb28834a24 --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/operation_py3.py @@ -0,0 +1,32 @@ +# 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 Operation(Model): + """Operation provided by provider. + + :param name: Name of the operation + :type name: str + :param display: Properties of the operation + :type display: ~quantum.models.OperationDisplay + """ + + _attribute_map = { + 'name': {'key': 'name', 'type': 'str'}, + 'display': {'key': 'display', 'type': 'OperationDisplay'}, + } + + def __init__(self, *, name: str=None, display=None, **kwargs) -> None: + super(Operation, self).__init__(**kwargs) + self.name = name + self.display = display diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_detail.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_detail.py new file mode 100644 index 00000000000..e3294d78387 --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_detail.py @@ -0,0 +1,32 @@ +# 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 PricingDetail(Model): + """Detailed pricing information for an sku. + + :param id: Unique id for this pricing information. + :type id: str + :param value: The unit cost of this sku. + :type value: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(PricingDetail, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.value = kwargs.get('value', None) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_detail_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_detail_py3.py new file mode 100644 index 00000000000..1f220717b39 --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_detail_py3.py @@ -0,0 +1,32 @@ +# 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 PricingDetail(Model): + """Detailed pricing information for an sku. + + :param id: Unique id for this pricing information. + :type id: str + :param value: The unit cost of this sku. + :type value: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'value': {'key': 'value', 'type': 'str'}, + } + + def __init__(self, *, id: str=None, value: str=None, **kwargs) -> None: + super(PricingDetail, self).__init__(**kwargs) + self.id = id + self.value = value diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_dimension.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_dimension.py new file mode 100644 index 00000000000..bb72e9e14dd --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_dimension.py @@ -0,0 +1,32 @@ +# 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 PricingDimension(Model): + """Information about pricing dimension. + + :param id: Unique id of this pricing dimension. + :type id: str + :param name: The display name of this pricing dimension. + :type name: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(PricingDimension, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.name = kwargs.get('name', None) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_dimension_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_dimension_py3.py new file mode 100644 index 00000000000..a8d98bce326 --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/pricing_dimension_py3.py @@ -0,0 +1,32 @@ +# 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 PricingDimension(Model): + """Information about pricing dimension. + + :param id: Unique id of this pricing dimension. + :type id: str + :param name: The display name of this pricing dimension. + :type name: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'name': {'key': 'name', 'type': 'str'}, + } + + def __init__(self, *, id: str=None, name: str=None, **kwargs) -> None: + super(PricingDimension, self).__init__(**kwargs) + self.id = id + self.name = name diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider.py index b613ad9558e..19d30bad957 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider.py @@ -13,16 +13,19 @@ class Provider(Model): - """Json representation of provider, used for json serialization and - deserialization and save the meta information of provider. + """Information about a Provider. A Provider is an entity that offers Targets + to run Azure Quantum Jobs. - :param provider_id: partner id field + :param provider_id: Unique id of this provider. :type provider_id: str - :param provider_sku: sku field + :param provider_sku: The sku associated with pricing information for this + provider. :type provider_sku: str - :param instance_uri: serviceUri field + :param instance_uri: A Uri identifying the specific instance of this + provider. :type instance_uri: str - :param application_name: application name field + :param application_name: The provider's marketplace application display + name. :type application_name: str :param provisioning_state: Provisioning status field. Possible values include: 'Succeeded', 'Launching', 'Updating', 'Deleting', 'Deleted', diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description.py index 6e2903041ee..34ff342a18d 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description.py @@ -13,20 +13,21 @@ class ProviderDescription(Model): - """Information about a Provider. + """Information about a Provider. A Provider is an entity that offers Targets + to run Azure Quantum Jobs. - :param id: Unique Provider's id. + :param id: Unique provider's id. :type id: str :param name: Provider's display name. :type name: str - :param properties: A list of Provider-specific properties. - :type properties: ~quantum.models.ProviderDescriptionProperties + :param properties: A list of provider-specific properties. + :type properties: ~quantum.models.ProviderProperties """ _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'name': {'key': 'name', 'type': 'str'}, - 'properties': {'key': 'properties', 'type': 'ProviderDescriptionProperties'}, + 'properties': {'key': 'properties', 'type': 'ProviderProperties'}, } def __init__(self, **kwargs): diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description_properties.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description_properties.py deleted file mode 100644 index ad6a269e0ab..00000000000 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description_properties.py +++ /dev/null @@ -1,49 +0,0 @@ -# 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 .provider_properties import ProviderProperties - - -class ProviderDescriptionProperties(ProviderProperties): - """A list of Provider-specific properties. - - :param description: Description about this Provider. - :type description: str - :param provider_type: Provider type. - :type provider_type: str - :param company: Company name. - :type company: str - :param default_endpoint: Provider's default endpoint. - :type default_endpoint: str - :param aad: Azure Active Directory info. - :type aad: ~quantum.models.ProviderPropertiesAad - :param managed_application: Provider's Managed-Application info - :type managed_application: - ~quantum.models.ProviderPropertiesManagedApplication - :param targets: The list of targets available from this provider - :type targets: list[~quantum.models.TargetDescription] - :param skus: The list of skus selected for this provider - :type skus: list[~quantum.models.SkuDescription] - """ - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'provider_type': {'key': 'providerType', 'type': 'str'}, - 'company': {'key': 'company', 'type': 'str'}, - 'default_endpoint': {'key': 'defaultEndpoint', 'type': 'str'}, - 'aad': {'key': 'aad', 'type': 'ProviderPropertiesAad'}, - 'managed_application': {'key': 'managedApplication', 'type': 'ProviderPropertiesManagedApplication'}, - 'targets': {'key': 'targets', 'type': '[TargetDescription]'}, - 'skus': {'key': 'skus', 'type': '[SkuDescription]'}, - } - - def __init__(self, **kwargs): - super(ProviderDescriptionProperties, self).__init__(**kwargs) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description_properties_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description_properties_py3.py deleted file mode 100644 index d61719b20aa..00000000000 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description_properties_py3.py +++ /dev/null @@ -1,49 +0,0 @@ -# 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 .provider_properties_py3 import ProviderProperties - - -class ProviderDescriptionProperties(ProviderProperties): - """A list of Provider-specific properties. - - :param description: Description about this Provider. - :type description: str - :param provider_type: Provider type. - :type provider_type: str - :param company: Company name. - :type company: str - :param default_endpoint: Provider's default endpoint. - :type default_endpoint: str - :param aad: Azure Active Directory info. - :type aad: ~quantum.models.ProviderPropertiesAad - :param managed_application: Provider's Managed-Application info - :type managed_application: - ~quantum.models.ProviderPropertiesManagedApplication - :param targets: The list of targets available from this provider - :type targets: list[~quantum.models.TargetDescription] - :param skus: The list of skus selected for this provider - :type skus: list[~quantum.models.SkuDescription] - """ - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'provider_type': {'key': 'providerType', 'type': 'str'}, - 'company': {'key': 'company', 'type': 'str'}, - 'default_endpoint': {'key': 'defaultEndpoint', 'type': 'str'}, - 'aad': {'key': 'aad', 'type': 'ProviderPropertiesAad'}, - 'managed_application': {'key': 'managedApplication', 'type': 'ProviderPropertiesManagedApplication'}, - 'targets': {'key': 'targets', 'type': '[TargetDescription]'}, - 'skus': {'key': 'skus', 'type': '[SkuDescription]'}, - } - - def __init__(self, *, description: str=None, provider_type: str=None, company: str=None, default_endpoint: str=None, aad=None, managed_application=None, targets=None, skus=None, **kwargs) -> None: - super(ProviderDescriptionProperties, self).__init__(description=description, provider_type=provider_type, company=company, default_endpoint=default_endpoint, aad=aad, managed_application=managed_application, targets=targets, skus=skus, **kwargs) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description_py3.py index 3b242ae5de7..bf65f995110 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description_py3.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_description_py3.py @@ -13,20 +13,21 @@ class ProviderDescription(Model): - """Information about a Provider. + """Information about a Provider. A Provider is an entity that offers Targets + to run Azure Quantum Jobs. - :param id: Unique Provider's id. + :param id: Unique provider's id. :type id: str :param name: Provider's display name. :type name: str - :param properties: A list of Provider-specific properties. - :type properties: ~quantum.models.ProviderDescriptionProperties + :param properties: A list of provider-specific properties. + :type properties: ~quantum.models.ProviderProperties """ _attribute_map = { 'id': {'key': 'id', 'type': 'str'}, 'name': {'key': 'name', 'type': 'str'}, - 'properties': {'key': 'properties', 'type': 'ProviderDescriptionProperties'}, + 'properties': {'key': 'properties', 'type': 'ProviderProperties'}, } def __init__(self, *, id: str=None, name: str=None, properties=None, **kwargs) -> None: diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties.py index 257b10d8b35..871b60f7410 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties.py @@ -15,7 +15,7 @@ class ProviderProperties(Model): """Provider properties. - :param description: Description about this Provider. + :param description: A description about this provider. :type description: str :param provider_type: Provider type. :type provider_type: str @@ -28,10 +28,15 @@ class ProviderProperties(Model): :param managed_application: Provider's Managed-Application info :type managed_application: ~quantum.models.ProviderPropertiesManagedApplication - :param targets: The list of targets available from this provider + :param targets: The list of targets available from this provider. :type targets: list[~quantum.models.TargetDescription] - :param skus: The list of skus selected for this provider + :param skus: The list of skus available from this provider. :type skus: list[~quantum.models.SkuDescription] + :param quota_dimensions: The list of quota dimensions from the provider. + :type quota_dimensions: list[~quantum.models.QuotaDimension] + :param pricing_dimensions: The list of pricing dimensions from the + provider. + :type pricing_dimensions: list[~quantum.models.PricingDimension] """ _attribute_map = { @@ -43,6 +48,8 @@ class ProviderProperties(Model): 'managed_application': {'key': 'managedApplication', 'type': 'ProviderPropertiesManagedApplication'}, 'targets': {'key': 'targets', 'type': '[TargetDescription]'}, 'skus': {'key': 'skus', 'type': '[SkuDescription]'}, + 'quota_dimensions': {'key': 'quotaDimensions', 'type': '[QuotaDimension]'}, + 'pricing_dimensions': {'key': 'pricingDimensions', 'type': '[PricingDimension]'}, } def __init__(self, **kwargs): @@ -55,3 +62,5 @@ def __init__(self, **kwargs): self.managed_application = kwargs.get('managed_application', None) self.targets = kwargs.get('targets', None) self.skus = kwargs.get('skus', None) + self.quota_dimensions = kwargs.get('quota_dimensions', None) + self.pricing_dimensions = kwargs.get('pricing_dimensions', None) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_managed_application.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_managed_application.py index 26f80f7cf1d..5e317751e8d 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_managed_application.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_managed_application.py @@ -15,9 +15,9 @@ class ProviderPropertiesManagedApplication(Model): """Provider's Managed-Application info. - :param publisher_id: Provider's publisher id + :param publisher_id: Provider's publisher id. :type publisher_id: str - :param offer_id: Provider's offer id + :param offer_id: Provider's offer id. :type offer_id: str """ diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_managed_application_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_managed_application_py3.py index bc7386224cf..5a40c2e70b9 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_managed_application_py3.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_managed_application_py3.py @@ -15,9 +15,9 @@ class ProviderPropertiesManagedApplication(Model): """Provider's Managed-Application info. - :param publisher_id: Provider's publisher id + :param publisher_id: Provider's publisher id. :type publisher_id: str - :param offer_id: Provider's offer id + :param offer_id: Provider's offer id. :type offer_id: str """ diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_py3.py index 9ea62ba68a1..6abe59e8976 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_py3.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_properties_py3.py @@ -15,7 +15,7 @@ class ProviderProperties(Model): """Provider properties. - :param description: Description about this Provider. + :param description: A description about this provider. :type description: str :param provider_type: Provider type. :type provider_type: str @@ -28,10 +28,15 @@ class ProviderProperties(Model): :param managed_application: Provider's Managed-Application info :type managed_application: ~quantum.models.ProviderPropertiesManagedApplication - :param targets: The list of targets available from this provider + :param targets: The list of targets available from this provider. :type targets: list[~quantum.models.TargetDescription] - :param skus: The list of skus selected for this provider + :param skus: The list of skus available from this provider. :type skus: list[~quantum.models.SkuDescription] + :param quota_dimensions: The list of quota dimensions from the provider. + :type quota_dimensions: list[~quantum.models.QuotaDimension] + :param pricing_dimensions: The list of pricing dimensions from the + provider. + :type pricing_dimensions: list[~quantum.models.PricingDimension] """ _attribute_map = { @@ -43,9 +48,11 @@ class ProviderProperties(Model): 'managed_application': {'key': 'managedApplication', 'type': 'ProviderPropertiesManagedApplication'}, 'targets': {'key': 'targets', 'type': '[TargetDescription]'}, 'skus': {'key': 'skus', 'type': '[SkuDescription]'}, + 'quota_dimensions': {'key': 'quotaDimensions', 'type': '[QuotaDimension]'}, + 'pricing_dimensions': {'key': 'pricingDimensions', 'type': '[PricingDimension]'}, } - def __init__(self, *, description: str=None, provider_type: str=None, company: str=None, default_endpoint: str=None, aad=None, managed_application=None, targets=None, skus=None, **kwargs) -> None: + def __init__(self, *, description: str=None, provider_type: str=None, company: str=None, default_endpoint: str=None, aad=None, managed_application=None, targets=None, skus=None, quota_dimensions=None, pricing_dimensions=None, **kwargs) -> None: super(ProviderProperties, self).__init__(**kwargs) self.description = description self.provider_type = provider_type @@ -55,3 +62,5 @@ def __init__(self, *, description: str=None, provider_type: str=None, company: s self.managed_application = managed_application self.targets = targets self.skus = skus + self.quota_dimensions = quota_dimensions + self.pricing_dimensions = pricing_dimensions diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_py3.py index 220e5bc469b..e8fb15f2af9 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_py3.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/provider_py3.py @@ -13,16 +13,19 @@ class Provider(Model): - """Json representation of provider, used for json serialization and - deserialization and save the meta information of provider. + """Information about a Provider. A Provider is an entity that offers Targets + to run Azure Quantum Jobs. - :param provider_id: partner id field + :param provider_id: Unique id of this provider. :type provider_id: str - :param provider_sku: sku field + :param provider_sku: The sku associated with pricing information for this + provider. :type provider_sku: str - :param instance_uri: serviceUri field + :param instance_uri: A Uri identifying the specific instance of this + provider. :type instance_uri: str - :param application_name: application name field + :param application_name: The provider's marketplace application display + name. :type application_name: str :param provisioning_state: Provisioning status field. Possible values include: 'Succeeded', 'Launching', 'Updating', 'Deleting', 'Deleted', diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quantum_workspace.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quantum_workspace.py index f40f700ad6a..0fb6ac896ef 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quantum_workspace.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quantum_workspace.py @@ -18,27 +18,29 @@ class QuantumWorkspace(Model): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Gets or sets the id for the resource. + :ivar id: The unique id for this workspace. :vartype id: str - :ivar name: Gets or sets the name of the resource definition. + :ivar name: The name of this workspace. :vartype name: str - :ivar type: Gets or sets the type of the resource definition. + :ivar type: The type of this workspace. :vartype type: str - :param location: Gets or sets the resource location. + :param location: The location (region) of this workspace. :type location: str - :param providers: Providers selected for a Workspace + :param providers: List of Providers selected for this Workspace :type providers: list[~quantum.models.Provider] - :param usable: Whether the current workspace is usable. Possible values - include: 'Yes', 'No', 'Partial' + :param usable: Whether the current workspace is ready to accept Jobs. + Possible values include: 'Yes', 'No', 'Partial' :type usable: str or ~quantum.models.UsableStatus :param provisioning_state: Provisioning status field. Possible values include: 'Succeeded', 'ProviderLaunching', 'ProviderUpdating', 'ProviderDeleting', 'ProviderProvisioning', 'Deleted', 'Failed' :type provisioning_state: str or ~quantum.models.ProvisioningStatus + :param resource_usage_id: Unique id to track resource usage. + :type resource_usage_id: str :param storage_account: ARM Resource Id of the storage account associated with this workspace. :type storage_account: str - :param tags: Gets or sets the tags. + :param tags: The tags associated with this workspace. :type tags: object :param identity: Managed Identity information :type identity: ~quantum.models.QuantumWorkspaceIdentity @@ -58,6 +60,7 @@ class QuantumWorkspace(Model): 'providers': {'key': 'properties.providers', 'type': '[Provider]'}, 'usable': {'key': 'properties.usable', 'type': 'str'}, 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, + 'resource_usage_id': {'key': 'properties.resourceUsageId', 'type': 'str'}, 'storage_account': {'key': 'properties.storageAccount', 'type': 'str'}, 'tags': {'key': 'tags', 'type': 'object'}, 'identity': {'key': 'identity', 'type': 'QuantumWorkspaceIdentity'}, @@ -72,6 +75,7 @@ def __init__(self, **kwargs): self.providers = kwargs.get('providers', None) self.usable = kwargs.get('usable', None) self.provisioning_state = kwargs.get('provisioning_state', None) + self.resource_usage_id = kwargs.get('resource_usage_id', None) self.storage_account = kwargs.get('storage_account', None) self.tags = kwargs.get('tags', None) self.identity = kwargs.get('identity', None) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quantum_workspace_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quantum_workspace_py3.py index bdbb1932b01..22bdc0407ba 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quantum_workspace_py3.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quantum_workspace_py3.py @@ -18,27 +18,29 @@ class QuantumWorkspace(Model): Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Gets or sets the id for the resource. + :ivar id: The unique id for this workspace. :vartype id: str - :ivar name: Gets or sets the name of the resource definition. + :ivar name: The name of this workspace. :vartype name: str - :ivar type: Gets or sets the type of the resource definition. + :ivar type: The type of this workspace. :vartype type: str - :param location: Gets or sets the resource location. + :param location: The location (region) of this workspace. :type location: str - :param providers: Providers selected for a Workspace + :param providers: List of Providers selected for this Workspace :type providers: list[~quantum.models.Provider] - :param usable: Whether the current workspace is usable. Possible values - include: 'Yes', 'No', 'Partial' + :param usable: Whether the current workspace is ready to accept Jobs. + Possible values include: 'Yes', 'No', 'Partial' :type usable: str or ~quantum.models.UsableStatus :param provisioning_state: Provisioning status field. Possible values include: 'Succeeded', 'ProviderLaunching', 'ProviderUpdating', 'ProviderDeleting', 'ProviderProvisioning', 'Deleted', 'Failed' :type provisioning_state: str or ~quantum.models.ProvisioningStatus + :param resource_usage_id: Unique id to track resource usage. + :type resource_usage_id: str :param storage_account: ARM Resource Id of the storage account associated with this workspace. :type storage_account: str - :param tags: Gets or sets the tags. + :param tags: The tags associated with this workspace. :type tags: object :param identity: Managed Identity information :type identity: ~quantum.models.QuantumWorkspaceIdentity @@ -58,12 +60,13 @@ class QuantumWorkspace(Model): 'providers': {'key': 'properties.providers', 'type': '[Provider]'}, 'usable': {'key': 'properties.usable', 'type': 'str'}, 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, + 'resource_usage_id': {'key': 'properties.resourceUsageId', 'type': 'str'}, 'storage_account': {'key': 'properties.storageAccount', 'type': 'str'}, 'tags': {'key': 'tags', 'type': 'object'}, 'identity': {'key': 'identity', 'type': 'QuantumWorkspaceIdentity'}, } - def __init__(self, *, location: str=None, providers=None, usable=None, provisioning_state=None, storage_account: str=None, tags=None, identity=None, **kwargs) -> None: + def __init__(self, *, location: str=None, providers=None, usable=None, provisioning_state=None, resource_usage_id: str=None, storage_account: str=None, tags=None, identity=None, **kwargs) -> None: super(QuantumWorkspace, self).__init__(**kwargs) self.id = None self.name = None @@ -72,6 +75,7 @@ def __init__(self, *, location: str=None, providers=None, usable=None, provision self.providers = providers self.usable = usable self.provisioning_state = provisioning_state + self.resource_usage_id = resource_usage_id self.storage_account = storage_account self.tags = tags self.identity = identity diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quota_dimension.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quota_dimension.py new file mode 100644 index 00000000000..9a1ac1d3bdc --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quota_dimension.py @@ -0,0 +1,58 @@ +# 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 QuotaDimension(Model): + """Information about a specific quota dimension. + + :param id: Unique id of this dimension. + :type id: str + :param scope: The scope of this quota dimension. + :type scope: str + :param period: The reset period of this quota dimension. + :type period: str + :param quota: The max limit of this dimension. + :type quota: float + :param name: The display name of this quota dimension. + :type name: str + :param description: A description about this quota dimension. + :type description: str + :param unit: The standard unit of measurement used for this quota + dimension. + :type unit: str + :param unit_plural: The standard unit of measurement used for this quota + dimension in plural form. + :type unit_plural: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'scope': {'key': 'scope', 'type': 'str'}, + 'period': {'key': 'period', 'type': 'str'}, + 'quota': {'key': 'quota', 'type': 'float'}, + 'name': {'key': 'name', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'unit': {'key': 'unit', 'type': 'str'}, + 'unit_plural': {'key': 'unitPlural', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(QuotaDimension, self).__init__(**kwargs) + self.id = kwargs.get('id', None) + self.scope = kwargs.get('scope', None) + self.period = kwargs.get('period', None) + self.quota = kwargs.get('quota', None) + self.name = kwargs.get('name', None) + self.description = kwargs.get('description', None) + self.unit = kwargs.get('unit', None) + self.unit_plural = kwargs.get('unit_plural', None) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quota_dimension_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quota_dimension_py3.py new file mode 100644 index 00000000000..f3c6f5dce9b --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/quota_dimension_py3.py @@ -0,0 +1,58 @@ +# 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 QuotaDimension(Model): + """Information about a specific quota dimension. + + :param id: Unique id of this dimension. + :type id: str + :param scope: The scope of this quota dimension. + :type scope: str + :param period: The reset period of this quota dimension. + :type period: str + :param quota: The max limit of this dimension. + :type quota: float + :param name: The display name of this quota dimension. + :type name: str + :param description: A description about this quota dimension. + :type description: str + :param unit: The standard unit of measurement used for this quota + dimension. + :type unit: str + :param unit_plural: The standard unit of measurement used for this quota + dimension in plural form. + :type unit_plural: str + """ + + _attribute_map = { + 'id': {'key': 'id', 'type': 'str'}, + 'scope': {'key': 'scope', 'type': 'str'}, + 'period': {'key': 'period', 'type': 'str'}, + 'quota': {'key': 'quota', 'type': 'float'}, + 'name': {'key': 'name', 'type': 'str'}, + 'description': {'key': 'description', 'type': 'str'}, + 'unit': {'key': 'unit', 'type': 'str'}, + 'unit_plural': {'key': 'unitPlural', 'type': 'str'}, + } + + def __init__(self, *, id: str=None, scope: str=None, period: str=None, quota: float=None, name: str=None, description: str=None, unit: str=None, unit_plural: str=None, **kwargs) -> None: + super(QuotaDimension, self).__init__(**kwargs) + self.id = id + self.scope = scope + self.period = period + self.quota = quota + self.name = name + self.description = description + self.unit = unit + self.unit_plural = unit_plural diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/sku_description.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/sku_description.py index fdfff1bff9a..f0fec975e7a 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/sku_description.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/sku_description.py @@ -13,16 +13,20 @@ class SkuDescription(Model): - """Descript provider's information to end customer. + """Information about a specific sku. - :param id: unique sku id + :param id: Unique sku id. :type id: str - :param name: display name of sku + :param name: Display name of this sku. :type name: str - :param description: Description about this sku + :param description: Description about this sku. :type description: str - :param targets: list of targets for the sku + :param targets: The list of targets available for this sku. :type targets: list[str] + :param quota_dimensions: The list of quota dimensions for this sku. + :type quota_dimensions: list[~quantum.models.QuotaDimension] + :param pricing_details: The list of pricing details for the sku. + :type pricing_details: list[~quantum.models.PricingDetail] """ _attribute_map = { @@ -30,6 +34,8 @@ class SkuDescription(Model): 'name': {'key': 'name', 'type': 'str'}, 'description': {'key': 'description', 'type': 'str'}, 'targets': {'key': 'targets', 'type': '[str]'}, + 'quota_dimensions': {'key': 'quotaDimensions', 'type': '[QuotaDimension]'}, + 'pricing_details': {'key': 'pricingDetails', 'type': '[PricingDetail]'}, } def __init__(self, **kwargs): @@ -38,3 +44,5 @@ def __init__(self, **kwargs): self.name = kwargs.get('name', None) self.description = kwargs.get('description', None) self.targets = kwargs.get('targets', None) + self.quota_dimensions = kwargs.get('quota_dimensions', None) + self.pricing_details = kwargs.get('pricing_details', None) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/sku_description_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/sku_description_py3.py index 8e66969bd09..2da15e5f79d 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/sku_description_py3.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/sku_description_py3.py @@ -13,16 +13,20 @@ class SkuDescription(Model): - """Descript provider's information to end customer. + """Information about a specific sku. - :param id: unique sku id + :param id: Unique sku id. :type id: str - :param name: display name of sku + :param name: Display name of this sku. :type name: str - :param description: Description about this sku + :param description: Description about this sku. :type description: str - :param targets: list of targets for the sku + :param targets: The list of targets available for this sku. :type targets: list[str] + :param quota_dimensions: The list of quota dimensions for this sku. + :type quota_dimensions: list[~quantum.models.QuotaDimension] + :param pricing_details: The list of pricing details for the sku. + :type pricing_details: list[~quantum.models.PricingDetail] """ _attribute_map = { @@ -30,11 +34,15 @@ class SkuDescription(Model): 'name': {'key': 'name', 'type': 'str'}, 'description': {'key': 'description', 'type': 'str'}, 'targets': {'key': 'targets', 'type': '[str]'}, + 'quota_dimensions': {'key': 'quotaDimensions', 'type': '[QuotaDimension]'}, + 'pricing_details': {'key': 'pricingDetails', 'type': '[PricingDetail]'}, } - def __init__(self, *, id: str=None, name: str=None, description: str=None, targets=None, **kwargs) -> None: + def __init__(self, *, id: str=None, name: str=None, description: str=None, targets=None, quota_dimensions=None, pricing_details=None, **kwargs) -> None: super(SkuDescription, self).__init__(**kwargs) self.id = id self.name = name self.description = description self.targets = targets + self.quota_dimensions = quota_dimensions + self.pricing_details = pricing_details diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/target_description.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/target_description.py index 30800fb768d..c9be4427693 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/target_description.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/target_description.py @@ -13,17 +13,20 @@ class TargetDescription(Model): - """Descript provider's target information to end customer. + """Information about a Target. A target is the component that can process a + specific type of Job. - :param id: Unique target id + :param id: Unique target id. :type id: str - :param name: Display name of target + :param name: Display name of this target. :type name: str - :param description: Description about this sku + :param description: A description about this target. :type description: str - :param accepted_data_formats: List of data formats + :param accepted_data_formats: List of data formats accepted by this + target. :type accepted_data_formats: list[str] - :param accepted_content_encodings: List of content encodings + :param accepted_content_encodings: List of content encodings accepted by + this target. :type accepted_content_encodings: list[str] """ diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/target_description_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/target_description_py3.py index 1b27f38c47f..79072576249 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/target_description_py3.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/target_description_py3.py @@ -13,17 +13,20 @@ class TargetDescription(Model): - """Descript provider's target information to end customer. + """Information about a Target. A target is the component that can process a + specific type of Job. - :param id: Unique target id + :param id: Unique target id. :type id: str - :param name: Display name of target + :param name: Display name of this target. :type name: str - :param description: Description about this sku + :param description: A description about this target. :type description: str - :param accepted_data_formats: List of data formats + :param accepted_data_formats: List of data formats accepted by this + target. :type accepted_data_formats: list[str] - :param accepted_content_encodings: List of content encodings + :param accepted_content_encodings: List of content encodings accepted by + this target. :type accepted_content_encodings: list[str] """ diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/workspace_resource_properties.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/workspace_resource_properties.py deleted file mode 100644 index af79cf5042c..00000000000 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/workspace_resource_properties.py +++ /dev/null @@ -1,44 +0,0 @@ -# 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 WorkspaceResourceProperties(Model): - """Properties of a Workspace. - - :param providers: Providers selected for a Workspace - :type providers: list[~quantum.models.Provider] - :param usable: Whether the current workspace is usable. Possible values - include: 'Yes', 'No', 'Partial' - :type usable: str or ~quantum.models.UsableStatus - :param provisioning_state: Provisioning status field. Possible values - include: 'Succeeded', 'ProviderLaunching', 'ProviderUpdating', - 'ProviderDeleting', 'ProviderProvisioning', 'Deleted', 'Failed' - :type provisioning_state: str or ~quantum.models.ProvisioningStatus - :param storage_account: ARM Resource Id of the storage account associated - with this workspace. - :type storage_account: str - """ - - _attribute_map = { - 'providers': {'key': 'providers', 'type': '[Provider]'}, - 'usable': {'key': 'usable', 'type': 'str'}, - 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, - 'storage_account': {'key': 'storageAccount', 'type': 'str'}, - } - - def __init__(self, **kwargs): - super(WorkspaceResourceProperties, self).__init__(**kwargs) - self.providers = kwargs.get('providers', None) - self.usable = kwargs.get('usable', None) - self.provisioning_state = kwargs.get('provisioning_state', None) - self.storage_account = kwargs.get('storage_account', None) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/workspace_resource_properties_py3.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/workspace_resource_properties_py3.py deleted file mode 100644 index 7740298e3fc..00000000000 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/models/workspace_resource_properties_py3.py +++ /dev/null @@ -1,44 +0,0 @@ -# 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 WorkspaceResourceProperties(Model): - """Properties of a Workspace. - - :param providers: Providers selected for a Workspace - :type providers: list[~quantum.models.Provider] - :param usable: Whether the current workspace is usable. Possible values - include: 'Yes', 'No', 'Partial' - :type usable: str or ~quantum.models.UsableStatus - :param provisioning_state: Provisioning status field. Possible values - include: 'Succeeded', 'ProviderLaunching', 'ProviderUpdating', - 'ProviderDeleting', 'ProviderProvisioning', 'Deleted', 'Failed' - :type provisioning_state: str or ~quantum.models.ProvisioningStatus - :param storage_account: ARM Resource Id of the storage account associated - with this workspace. - :type storage_account: str - """ - - _attribute_map = { - 'providers': {'key': 'providers', 'type': '[Provider]'}, - 'usable': {'key': 'usable', 'type': 'str'}, - 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, - 'storage_account': {'key': 'storageAccount', 'type': 'str'}, - } - - def __init__(self, *, providers=None, usable=None, provisioning_state=None, storage_account: str=None, **kwargs) -> None: - super(WorkspaceResourceProperties, self).__init__(**kwargs) - self.providers = providers - self.usable = usable - self.provisioning_state = provisioning_state - self.storage_account = storage_account diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/operations/__init__.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/operations/__init__.py index 67b413f9988..bcb03834269 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/operations/__init__.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/operations/__init__.py @@ -11,8 +11,10 @@ from .workspaces_operations import WorkspacesOperations from .offerings_operations import OfferingsOperations +from .operations import Operations __all__ = [ 'WorkspacesOperations', 'OfferingsOperations', + 'Operations', ] diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/operations/operations.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/operations/operations.py new file mode 100644 index 00000000000..5f9283469e6 --- /dev/null +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/operations/operations.py @@ -0,0 +1,95 @@ +# 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. +# -------------------------------------------------------------------------- + +import uuid +from msrest.pipeline import ClientRawResponse + +from .. import models + + +class Operations(object): + """Operations operations. + + :param client: Client for service requests. + :param config: Configuration of service client. + :param serializer: An object model serializer. + :param deserializer: An object model deserializer. + :ivar api_version: Client Api Version. Constant value: "2019-11-04-preview". + """ + + models = models + + def __init__(self, client, config, serializer, deserializer): + + self._client = client + self._serialize = serializer + self._deserialize = deserializer + self.api_version = "2019-11-04-preview" + + self.config = config + + def list( + self, custom_headers=None, raw=False, **operation_config): + """Returns list of operations. + + :param dict custom_headers: headers that will be added to the request + :param bool raw: returns the direct response alongside the + deserialized response + :param operation_config: :ref:`Operation configuration + overrides`. + :return: An iterator like instance of Operation + :rtype: ~quantum.models.OperationPaged[~quantum.models.Operation] + :raises: + :class:`ErrorResponseException` + """ + def internal_paging(next_link=None, raw=False): + + if not next_link: + # Construct URL + url = self.list.metadata['url'] + + # Construct parameters + query_parameters = {} + query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + + else: + url = next_link + query_parameters = {} + + # Construct headers + header_parameters = {} + header_parameters['Accept'] = 'application/json' + if self.config.generate_client_request_id: + header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) + if custom_headers: + header_parameters.update(custom_headers) + if self.config.accept_language is not None: + header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') + + # Construct and send request + request = self._client.get(url, query_parameters, header_parameters) + response = self._client.send(request, stream=False, **operation_config) + + if response.status_code not in [200]: + raise models.ErrorResponseException(self._deserialize, response) + + return response + + # Deserialize response + deserialized = models.OperationPaged(internal_paging, self._deserialize.dependencies) + + if raw: + header_dict = {} + client_raw_response = models.OperationPaged(internal_paging, self._deserialize.dependencies, header_dict) + return client_raw_response + + return deserialized + list.metadata = {'url': '/providers/Microsoft.Quantum/operations'} diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/operations/workspaces_operations.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/operations/workspaces_operations.py index 5969c8cc7b2..4d625e212ff 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/operations/workspaces_operations.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/operations/workspaces_operations.py @@ -100,10 +100,10 @@ def get( get.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Quantum/workspaces/{workspaceName}'} - def _create_and_update_initial( + def _create_or_update_initial( self, resource_group_name, workspace_name, quantum_workspace, custom_headers=None, raw=False, **operation_config): # Construct URL - url = self.create_and_update.metadata['url'] + url = self.create_or_update.metadata['url'] path_format_arguments = { 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str'), @@ -149,7 +149,7 @@ def _create_and_update_initial( return deserialized - def create_and_update( + def create_or_update( self, resource_group_name, workspace_name, quantum_workspace, custom_headers=None, raw=False, polling=True, **operation_config): """Creates or updates a workspace resource. @@ -173,7 +173,7 @@ def create_and_update( :raises: :class:`ErrorResponseException` """ - raw_result = self._create_and_update_initial( + raw_result = self._create_or_update_initial( resource_group_name=resource_group_name, workspace_name=workspace_name, quantum_workspace=quantum_workspace, @@ -198,7 +198,7 @@ def get_long_running_output(response): elif polling is False: polling_method = NoPolling() else: polling_method = polling return LROPoller(self._client, raw_result, get_long_running_output, polling_method) - create_and_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Quantum/workspaces/{workspaceName}'} + create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Quantum/workspaces/{workspaceName}'} def update( self, resource_group_name, workspace_name, quantum_workspace, custom_headers=None, raw=False, **operation_config): @@ -304,8 +304,6 @@ def _delete_initial( if response.status_code == 202: deserialized = self._deserialize('QuantumWorkspace', response) - if response.status_code == 204: - deserialized = self._deserialize('QuantumWorkspace', response) if raw: client_raw_response = ClientRawResponse(deserialized, response) diff --git a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/quantum_management_client.py b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/quantum_management_client.py index 6e2b08937ac..316df4d53be 100644 --- a/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/quantum_management_client.py +++ b/src/quantum/azext_quantum/vendored_sdks/azure_mgmt_quantum/quantum_management_client.py @@ -15,6 +15,7 @@ from .version import VERSION from .operations.workspaces_operations import WorkspacesOperations from .operations.offerings_operations import OfferingsOperations +from .operations.operations import Operations from . import models @@ -60,6 +61,8 @@ class QuantumManagementClient(SDKClient): :vartype workspaces: quantum.operations.WorkspacesOperations :ivar offerings: Offerings operations :vartype offerings: quantum.operations.OfferingsOperations + :ivar operations: Operations operations + :vartype operations: quantum.operations.Operations :param credentials: Credentials needed for the client to connect to Azure. :type credentials: :mod:`A msrestazure Credentials @@ -84,3 +87,5 @@ def __init__( self._client, self.config, self._serialize, self._deserialize) self.offerings = OfferingsOperations( self._client, self.config, self._serialize, self._deserialize) + self.operations = Operations( + self._client, self.config, self._serialize, self._deserialize)