1# --------------------------------------------------------------------------------------------
2# Copyright (c) Microsoft Corporation. All rights reserved.
3# Licensed under the MIT License. See License.txt in the project root for license information.
4# --------------------------------------------------------------------------------------------
5
6
7def cf_relay(cli_ctx, **_):
8    from azure.cli.core.commands.client_factory import get_mgmt_service_client
9    from azure.mgmt.relay import RelayManagementClient
10    return get_mgmt_service_client(cli_ctx, RelayManagementClient)
11
12
13def namespaces_mgmt_client_factory(cli_ctx, _):
14    return cf_relay(cli_ctx).namespaces
15
16
17def wcfrelays_mgmt_client_factory(cli_ctx, _):
18    return cf_relay(cli_ctx).wcf_relays
19
20
21def hycos_mgmt_client_factory(cli_ctx, _):
22    return cf_relay(cli_ctx).hybrid_connections
23