From f8fa234a3f08af56bcc833c696036c02184037ec Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Mon, 4 Jan 2021 02:32:25 +0000 Subject: [PATCH] CodeGen from PR 12045 in Azure/azure-rest-api-specs Merge a19a6096de895d815bd9377841b70564c35a886c into e5c779c267ed9d5ae7115ca71e16f3a6e6152bdd --- .../redhatopenshift/v2020_04_30/__init__.py | 6 +-- ...y => _azure_red_hat_open_shift4_client.py} | 12 ++--- .../v2020_04_30/_configuration.py | 6 +-- .../v2020_04_30/models/_models.py | 50 +++++++++++-------- .../v2020_04_30/models/_models_py3.py | 50 +++++++++++-------- .../_open_shift_clusters_operations.py | 25 +++------- .../v2020_04_30/operations/_operations.py | 3 +- 7 files changed, 80 insertions(+), 72 deletions(-) rename sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/{_azure_red_hat_open_shift_client.py => _azure_red_hat_open_shift4_client.py} (81%) diff --git a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/__init__.py b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/__init__.py index a1d37ffb0176..1809a50348b9 100644 --- a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/__init__.py +++ b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/__init__.py @@ -9,9 +9,9 @@ # regenerated. # -------------------------------------------------------------------------- -from ._configuration import AzureRedHatOpenShiftClientConfiguration -from ._azure_red_hat_open_shift_client import AzureRedHatOpenShiftClient -__all__ = ['AzureRedHatOpenShiftClient', 'AzureRedHatOpenShiftClientConfiguration'] +from ._configuration import AzureRedHatOpenShift4ClientConfiguration +from ._azure_red_hat_open_shift4_client import AzureRedHatOpenShift4Client +__all__ = ['AzureRedHatOpenShift4Client', 'AzureRedHatOpenShift4ClientConfiguration'] from .version import VERSION diff --git a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/_azure_red_hat_open_shift_client.py b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/_azure_red_hat_open_shift4_client.py similarity index 81% rename from sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/_azure_red_hat_open_shift_client.py rename to sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/_azure_red_hat_open_shift4_client.py index 618263ae95e8..1c997bb26e1a 100644 --- a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/_azure_red_hat_open_shift_client.py +++ b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/_azure_red_hat_open_shift4_client.py @@ -12,17 +12,17 @@ from msrest.service_client import SDKClient from msrest import Serializer, Deserializer -from ._configuration import AzureRedHatOpenShiftClientConfiguration +from ._configuration import AzureRedHatOpenShift4ClientConfiguration from .operations import Operations from .operations import OpenShiftClustersOperations from . import models -class AzureRedHatOpenShiftClient(SDKClient): - """Rest API for Azure Red Hat OpenShift +class AzureRedHatOpenShift4Client(SDKClient): + """Rest API for Azure Red Hat OpenShift 4 :ivar config: Configuration for client. - :vartype config: AzureRedHatOpenShiftClientConfiguration + :vartype config: AzureRedHatOpenShift4ClientConfiguration :ivar operations: Operations operations :vartype operations: azure.mgmt.redhatopenshift.v2020_04_30.operations.Operations @@ -40,8 +40,8 @@ class AzureRedHatOpenShiftClient(SDKClient): def __init__( self, credentials, subscription_id, base_url=None): - self.config = AzureRedHatOpenShiftClientConfiguration(credentials, subscription_id, base_url) - super(AzureRedHatOpenShiftClient, self).__init__(self.config.credentials, self.config) + self.config = AzureRedHatOpenShift4ClientConfiguration(credentials, subscription_id, base_url) + super(AzureRedHatOpenShift4Client, self).__init__(self.config.credentials, self.config) client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} self.api_version = '2020-04-30' diff --git a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/_configuration.py b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/_configuration.py index 37a5c2094b2b..006522736df5 100644 --- a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/_configuration.py +++ b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/_configuration.py @@ -13,8 +13,8 @@ from .version import VERSION -class AzureRedHatOpenShiftClientConfiguration(AzureConfiguration): - """Configuration for AzureRedHatOpenShiftClient +class AzureRedHatOpenShift4ClientConfiguration(AzureConfiguration): + """Configuration for AzureRedHatOpenShift4Client Note that all parameters used to create this instance are saved as instance attributes. @@ -36,7 +36,7 @@ def __init__( if not base_url: base_url = 'https://management.azure.com' - super(AzureRedHatOpenShiftClientConfiguration, self).__init__(base_url) + super(AzureRedHatOpenShift4ClientConfiguration, self).__init__(base_url) # Starting Autorest.Python 4.0.64, make connection pool activated by default self.keep_alive = True diff --git a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/models/_models.py b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/models/_models.py index 0f414e4178af..11a24a4c38c4 100644 --- a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/models/_models.py +++ b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/models/_models.py @@ -42,16 +42,19 @@ def __init__(self, **kwargs): class Resource(Model): """Resource. + Common fields that are returned in the response for all Azure Resource + Manager resources. + Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ @@ -75,19 +78,21 @@ def __init__(self, **kwargs): class AzureEntityResource(Resource): - """The resource model definition for a Azure Resource Manager resource with an - etag. + """Entity Resource. + + The resource model definition for an Azure Resource Manager resource with + an etag. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar etag: Resource Etag. :vartype etag: str @@ -315,20 +320,23 @@ def __init__(self, **kwargs): class TrackedResource(Resource): - """The resource model definition for a ARM tracked top level resource. + """Tracked Resource. + + The resource model definition for an Azure Resource Manager tracked top + level resource which has 'tags' and a 'location'. 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: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -365,13 +373,13 @@ class OpenShiftCluster(TrackedResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -554,19 +562,21 @@ def __init__(self, **kwargs): class ProxyResource(Resource): - """The resource model definition for a ARM proxy resource. It will have - everything other than required location and tags. + """Proxy Resource. + + The resource model definition for a Azure Resource Manager proxy resource. + It will not have tags and a location. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ diff --git a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/models/_models_py3.py b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/models/_models_py3.py index 896d58d5f6b1..d8c013bcfe25 100644 --- a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/models/_models_py3.py +++ b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/models/_models_py3.py @@ -42,16 +42,19 @@ def __init__(self, *, visibility=None, url: str=None, ip: str=None, **kwargs) -> class Resource(Model): """Resource. + Common fields that are returned in the response for all Azure Resource + Manager resources. + Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ @@ -75,19 +78,21 @@ def __init__(self, **kwargs) -> None: class AzureEntityResource(Resource): - """The resource model definition for a Azure Resource Manager resource with an - etag. + """Entity Resource. + + The resource model definition for an Azure Resource Manager resource with + an etag. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :ivar etag: Resource Etag. :vartype etag: str @@ -315,20 +320,23 @@ def __init__(self, *, pod_cidr: str=None, service_cidr: str=None, **kwargs) -> N class TrackedResource(Resource): - """The resource model definition for a ARM tracked top level resource. + """Tracked Resource. + + The resource model definition for an Azure Resource Manager tracked top + level resource which has 'tags' and a 'location'. 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: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -365,13 +373,13 @@ class OpenShiftCluster(TrackedResource): All required parameters must be populated in order to send to Azure. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str :param tags: Resource tags. :type tags: dict[str, str] @@ -554,19 +562,21 @@ def __init__(self, *, name: str=None, display=None, origin: str=None, **kwargs) class ProxyResource(Resource): - """The resource model definition for a ARM proxy resource. It will have - everything other than required location and tags. + """Proxy Resource. + + The resource model definition for a Azure Resource Manager proxy resource. + It will not have tags and a location. Variables are only populated by the server, and will be ignored when sending a request. - :ivar id: Fully qualified resource Id for the resource. Ex - + :ivar id: Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} :vartype id: str :ivar name: The name of the resource :vartype name: str - :ivar type: The type of the resource. Ex- - Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts. + :ivar type: The type of the resource. E.g. + "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" :vartype type: str """ diff --git a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/operations/_open_shift_clusters_operations.py b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/operations/_open_shift_clusters_operations.py index 6e429f0d2f14..0dd01c011f66 100644 --- a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/operations/_open_shift_clusters_operations.py +++ b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/operations/_open_shift_clusters_operations.py @@ -45,8 +45,7 @@ def list( self, custom_headers=None, raw=False, **operation_config): """Lists OpenShift clusters in the specified subscription. - Lists OpenShift clusters in the specified subscription. The operation - returns properties of each OpenShift cluster. + The operation returns properties of each OpenShift cluster. :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the @@ -115,8 +114,7 @@ def list_by_resource_group( """Lists OpenShift clusters in the specified subscription and resource group. - Lists OpenShift clusters in the specified subscription and resource - group. The operation returns properties of each OpenShift cluster. + The operation returns properties of each OpenShift cluster. :param resource_group_name: The name of the resource group. The name is case insensitive. @@ -189,9 +187,7 @@ def get( """Gets a OpenShift cluster with the specified subscription, resource group and resource name. - Gets a OpenShift cluster with the specified subscription, resource - group and resource name. The operation returns properties of a - OpenShift cluster. + The operation returns properties of a OpenShift cluster. :param resource_group_name: The name of the resource group. The name is case insensitive. @@ -309,9 +305,7 @@ def create_or_update( """Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name. - Creates or updates a OpenShift cluster with the specified subscription, - resource group and resource name. The operation returns properties of - a OpenShift cluster. + The operation returns properties of a OpenShift cluster. :param resource_group_name: The name of the resource group. The name is case insensitive. @@ -404,8 +398,7 @@ def delete( """Deletes a OpenShift cluster with the specified subscription, resource group and resource name. - Deletes a OpenShift cluster with the specified subscription, resource - group and resource name. The operation returns nothing. + The operation returns nothing. :param resource_group_name: The name of the resource group. The name is case insensitive. @@ -502,9 +495,7 @@ def update( """Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name. - Creates or updates a OpenShift cluster with the specified subscription, - resource group and resource name. The operation returns properties of - a OpenShift cluster. + The operation returns properties of a OpenShift cluster. :param resource_group_name: The name of the resource group. The name is case insensitive. @@ -559,9 +550,7 @@ def list_credentials( """Lists credentials of an OpenShift cluster with the specified subscription, resource group and resource name. - Lists credentials of an OpenShift cluster with the specified - subscription, resource group and resource name. The operation returns - the credentials. + The operation returns the credentials. :param resource_group_name: The name of the resource group. The name is case insensitive. diff --git a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/operations/_operations.py b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/operations/_operations.py index cbce2cb960b2..3aedf13831e8 100644 --- a/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/operations/_operations.py +++ b/sdk/redhatopenshift/azure-mgmt-redhatopenshift/azure/mgmt/redhatopenshift/v2020_04_30/operations/_operations.py @@ -43,8 +43,7 @@ def list( self, custom_headers=None, raw=False, **operation_config): """Lists all of the available RP operations. - Lists all of the available RP operations. The operation returns the RP - operations. + The operation returns the RP operations. :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the