Skip to content

Commit 7fc1dc3

Browse files
author
SDKAuto
committed
CodeGen from PR 11639 in Azure/azure-rest-api-specs
Merge b4b64803111a6a3c3e13503104b6c7b35b6f9ec7 into 7c8fd7f
1 parent d0d46ed commit 7fc1dc3

File tree

12 files changed

+1645
-0
lines changed

12 files changed

+1645
-0
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from ._configuration import windowsesuClientConfiguration
13+
from ._windowsesu_client import windowsesuClient
14+
__all__ = ['windowsesuClient', 'windowsesuClientConfiguration']
15+
16+
from .version import VERSION
17+
18+
__version__ = VERSION
19+
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
from msrestazure import AzureConfiguration
12+
13+
from .version import VERSION
14+
15+
16+
class windowsesuClientConfiguration(AzureConfiguration):
17+
"""Configuration for windowsesuClient
18+
Note that all parameters used to create this instance are saved as instance
19+
attributes.
20+
21+
:param credentials: Credentials needed for the client to connect to Azure.
22+
:type credentials: :mod:`A msrestazure Credentials
23+
object<msrestazure.azure_active_directory>`
24+
:param subscription_id: The ID of the target subscription.
25+
:type subscription_id: str
26+
:param str base_url: Service URL
27+
"""
28+
29+
def __init__(
30+
self, credentials, subscription_id, base_url=None):
31+
32+
if credentials is None:
33+
raise ValueError("Parameter 'credentials' must not be None.")
34+
if subscription_id is None:
35+
raise ValueError("Parameter 'subscription_id' must not be None.")
36+
if not base_url:
37+
base_url = 'https://management.azure.com'
38+
39+
super(windowsesuClientConfiguration, self).__init__(base_url)
40+
41+
# Starting Autorest.Python 4.0.64, make connection pool activated by default
42+
self.keep_alive = True
43+
44+
self.add_user_agent('azure-mgmt-windowsesu/{}'.format(VERSION))
45+
self.add_user_agent('Azure-SDK-For-Python')
46+
47+
self.credentials = credentials
48+
self.subscription_id = subscription_id
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
from msrest.service_client import SDKClient
13+
from msrest import Serializer, Deserializer
14+
15+
from ._configuration import windowsesuClientConfiguration
16+
from .operations import Operations
17+
from .operations import MultipleActivationKeysOperations
18+
from . import models
19+
20+
21+
class windowsesuClient(SDKClient):
22+
"""Manage Multi-Access Keys (MAK) that enable Windows Extended Security Updates (ESU).
23+
24+
:ivar config: Configuration for client.
25+
:vartype config: windowsesuClientConfiguration
26+
27+
:ivar operations: Operations operations
28+
:vartype operations: azure.mgmt.windowsesu.operations.Operations
29+
:ivar multiple_activation_keys: MultipleActivationKeys operations
30+
:vartype multiple_activation_keys: azure.mgmt.windowsesu.operations.MultipleActivationKeysOperations
31+
32+
:param credentials: Credentials needed for the client to connect to Azure.
33+
:type credentials: :mod:`A msrestazure Credentials
34+
object<msrestazure.azure_active_directory>`
35+
:param subscription_id: The ID of the target subscription.
36+
:type subscription_id: str
37+
:param str base_url: Service URL
38+
"""
39+
40+
def __init__(
41+
self, credentials, subscription_id, base_url=None):
42+
43+
self.config = windowsesuClientConfiguration(credentials, subscription_id, base_url)
44+
super(windowsesuClient, self).__init__(self.config.credentials, self.config)
45+
46+
client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)}
47+
self.api_version = '2019-09-16-preview'
48+
self._serialize = Serializer(client_models)
49+
self._deserialize = Deserializer(client_models)
50+
51+
self.operations = Operations(
52+
self._client, self.config, self._serialize, self._deserialize)
53+
self.multiple_activation_keys = MultipleActivationKeysOperations(
54+
self._client, self.config, self._serialize, self._deserialize)
Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
# coding=utf-8
2+
# --------------------------------------------------------------------------
3+
# Copyright (c) Microsoft Corporation. All rights reserved.
4+
# Licensed under the MIT License. See License.txt in the project root for
5+
# license information.
6+
#
7+
# Code generated by Microsoft (R) AutoRest Code Generator.
8+
# Changes may cause incorrect behavior and will be lost if the code is
9+
# regenerated.
10+
# --------------------------------------------------------------------------
11+
12+
try:
13+
from ._models_py3 import AzureEntityResource
14+
from ._models_py3 import ErrorDefinition
15+
from ._models_py3 import ErrorResponse, ErrorResponseException
16+
from ._models_py3 import MultipleActivationKey
17+
from ._models_py3 import MultipleActivationKeyUpdate
18+
from ._models_py3 import Operation
19+
from ._models_py3 import OperationDisplay
20+
from ._models_py3 import ProxyResource
21+
from ._models_py3 import Resource
22+
from ._models_py3 import TrackedResource
23+
except (SyntaxError, ImportError):
24+
from ._models import AzureEntityResource
25+
from ._models import ErrorDefinition
26+
from ._models import ErrorResponse, ErrorResponseException
27+
from ._models import MultipleActivationKey
28+
from ._models import MultipleActivationKeyUpdate
29+
from ._models import Operation
30+
from ._models import OperationDisplay
31+
from ._models import ProxyResource
32+
from ._models import Resource
33+
from ._models import TrackedResource
34+
from ._paged_models import MultipleActivationKeyPaged
35+
from ._paged_models import OperationPaged
36+
from ._windowsesu_client_enums import (
37+
OsType,
38+
SupportType,
39+
ProvisioningState,
40+
)
41+
42+
__all__ = [
43+
'AzureEntityResource',
44+
'ErrorDefinition',
45+
'ErrorResponse', 'ErrorResponseException',
46+
'MultipleActivationKey',
47+
'MultipleActivationKeyUpdate',
48+
'Operation',
49+
'OperationDisplay',
50+
'ProxyResource',
51+
'Resource',
52+
'TrackedResource',
53+
'OperationPaged',
54+
'MultipleActivationKeyPaged',
55+
'OsType',
56+
'SupportType',
57+
'ProvisioningState',
58+
]

0 commit comments

Comments
 (0)