Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

[Network] Generate code by autorest.python 5.16.0 and test #24353

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,12 @@
# --------------------------------------------------------------------------
from msrest import Serializer, Deserializer
from typing import TYPE_CHECKING
import warnings

from azure.core.exceptions import ClientAuthenticationError, HttpResponseError, ResourceExistsError, ResourceNotFoundError, map_error
from azure.core.paging import ItemPaged
from azure.core.pipeline import PipelineResponse
from azure.core.pipeline.transport import HttpRequest, HttpResponse
from azure.core.polling import LROPoller, NoPolling, PollingMethod
from azure.mgmt.core.exceptions import ARMErrorFormat
from azure.mgmt.core.polling.arm_polling import ARMPolling
from . import models as _models

if TYPE_CHECKING:
# pylint: disable=unused-import,ungrouped-imports
from typing import Any, Callable, Dict, Generic, Iterable, Optional, TypeVar, Union
from typing import Any, Iterable, Optional

from azure.core.paging import ItemPaged
from azure.core.polling import LROPoller
Expand All @@ -34,7 +27,7 @@ def begin_delete_bastion_shareable_link( # pylint: disable=inconsistent-return-
self,
resource_group_name, # type: str
bastion_host_name, # type: str
bsl_request, # type: "_models.BastionShareableLinkListRequest"
bsl_request, # type: _models.BastionShareableLinkListRequest
**kwargs # type: Any
):
# type: (...) -> LROPoller[None]
Expand Down Expand Up @@ -84,8 +77,6 @@ def begin_delete_bastion_shareable_link( # pylint: disable=inconsistent-return-
from .v2020_11_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-02-01':
from .v2021_02_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-05-01':
from .v2021_05_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import NetworkManagementClientOperationsMixin as OperationClass
else:
Expand All @@ -102,10 +93,10 @@ def begin_generatevirtualwanvpnserverconfigurationvpnprofile(
self,
resource_group_name, # type: str
virtual_wan_name, # type: str
vpn_client_params, # type: "_models.VirtualWanVpnProfileParameters"
vpn_client_params, # type: _models.VirtualWanVpnProfileParameters
**kwargs # type: Any
):
# type: (...) -> LROPoller["_models.VpnProfileResponse"]
# type: (...) -> LROPoller[_models.VpnProfileResponse]
"""Generates a unique VPN profile for P2S clients for VirtualWan and associated
VpnServerConfiguration combination in the specified resource group.

Expand Down Expand Up @@ -159,8 +150,6 @@ def begin_generatevirtualwanvpnserverconfigurationvpnprofile(
from .v2020_11_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-02-01':
from .v2021_02_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-05-01':
from .v2021_05_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import NetworkManagementClientOperationsMixin as OperationClass
else:
Expand All @@ -179,7 +168,7 @@ def begin_get_active_sessions(
bastion_host_name, # type: str
**kwargs # type: Any
):
# type: (...) -> LROPoller[ItemPaged["_models.BastionActiveSessionListResult"]]
# type: (...) -> LROPoller[ItemPaged[_models.BastionActiveSessionListResult]]
"""Returns the list of currently active sessions on the Bastion.

:param resource_group_name: The name of the resource group.
Expand Down Expand Up @@ -226,8 +215,6 @@ def begin_get_active_sessions(
from .v2020_11_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-02-01':
from .v2021_02_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-05-01':
from .v2021_05_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import NetworkManagementClientOperationsMixin as OperationClass
else:
Expand All @@ -244,10 +231,10 @@ def begin_put_bastion_shareable_link(
self,
resource_group_name, # type: str
bastion_host_name, # type: str
bsl_request, # type: "_models.BastionShareableLinkListRequest"
bsl_request, # type: _models.BastionShareableLinkListRequest
**kwargs # type: Any
):
# type: (...) -> LROPoller[ItemPaged["_models.BastionShareableLinkListResult"]]
# type: (...) -> LROPoller[ItemPaged[_models.BastionShareableLinkListResult]]
"""Creates a Bastion Shareable Links for all the VMs specified in the request.

:param resource_group_name: The name of the resource group.
Expand Down Expand Up @@ -296,8 +283,6 @@ def begin_put_bastion_shareable_link(
from .v2020_11_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-02-01':
from .v2021_02_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-05-01':
from .v2021_05_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import NetworkManagementClientOperationsMixin as OperationClass
else:
Expand All @@ -316,7 +301,7 @@ def check_dns_name_availability(
domain_name_label, # type: str
**kwargs # type: Any
):
# type: (...) -> "_models.DnsNameAvailabilityResult"
# type: (...) -> _models.DnsNameAvailabilityResult
"""Checks whether a domain name in the cloudapp.azure.com zone is available for use.

:param location: The location of the domain name.
Expand Down Expand Up @@ -395,8 +380,6 @@ def check_dns_name_availability(
from .v2020_11_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-02-01':
from .v2021_02_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-05-01':
from .v2021_05_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import NetworkManagementClientOperationsMixin as OperationClass
else:
Expand All @@ -413,10 +396,10 @@ def disconnect_active_sessions(
self,
resource_group_name, # type: str
bastion_host_name, # type: str
session_ids, # type: "_models.SessionIds"
session_ids, # type: _models.SessionIds
**kwargs # type: Any
):
# type: (...) -> Iterable["_models.BastionSessionDeleteResult"]
# type: (...) -> Iterable[_models.BastionSessionDeleteResult]
"""Returns the list of currently active sessions on the Bastion.

:param resource_group_name: The name of the resource group.
Expand Down Expand Up @@ -458,8 +441,6 @@ def disconnect_active_sessions(
from .v2020_11_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-02-01':
from .v2021_02_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-05-01':
from .v2021_05_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import NetworkManagementClientOperationsMixin as OperationClass
else:
Expand All @@ -476,10 +457,10 @@ def get_bastion_shareable_link(
self,
resource_group_name, # type: str
bastion_host_name, # type: str
bsl_request, # type: "_models.BastionShareableLinkListRequest"
bsl_request, # type: _models.BastionShareableLinkListRequest
**kwargs # type: Any
):
# type: (...) -> Iterable["_models.BastionShareableLinkListResult"]
# type: (...) -> Iterable[_models.BastionShareableLinkListResult]
"""Return the Bastion Shareable Links for all the VMs specified in the request.

:param resource_group_name: The name of the resource group.
Expand Down Expand Up @@ -521,8 +502,6 @@ def get_bastion_shareable_link(
from .v2020_11_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-02-01':
from .v2021_02_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-05-01':
from .v2021_05_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import NetworkManagementClientOperationsMixin as OperationClass
else:
Expand All @@ -541,7 +520,7 @@ def supported_security_providers(
virtual_wan_name, # type: str
**kwargs # type: Any
):
# type: (...) -> "_models.VirtualWanSecurityProviders"
# type: (...) -> _models.VirtualWanSecurityProviders
"""Gives the supported security providers for the virtual wan.

:param resource_group_name: The resource group name.
Expand Down Expand Up @@ -598,8 +577,6 @@ def supported_security_providers(
from .v2020_11_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-02-01':
from .v2021_02_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-05-01':
from .v2021_05_01.operations import NetworkManagementClientOperationsMixin as OperationClass
elif api_version == '2021-08-01':
from .v2021_08_01.operations import NetworkManagementClientOperationsMixin as OperationClass
else:
Expand Down
Loading