Skip to content
Merged
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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions sdk/sql/azure-mgmt-sql/azure/mgmt/sql/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@
from .managed_database_security_alert_policy_py3 import ManagedDatabaseSecurityAlertPolicy
from .managed_server_security_alert_policy_py3 import ManagedServerSecurityAlertPolicy
from .sensitivity_label_py3 import SensitivityLabel
from .managed_instance_administrator_py3 import ManagedInstanceAdministrator
from .database_operation_py3 import DatabaseOperation
from .elastic_pool_operation_py3 import ElasticPoolOperation
from .max_size_capability_py3 import MaxSizeCapability
Expand Down Expand Up @@ -165,6 +166,8 @@
from .usage_py3 import Usage
from .managed_instance_py3 import ManagedInstance
from .managed_instance_update_py3 import ManagedInstanceUpdate
from .private_link_resource_properties_py3 import PrivateLinkResourceProperties
from .private_link_resource_py3 import PrivateLinkResource
except (SyntaxError, ImportError):
from .recoverable_database import RecoverableDatabase
from .restorable_dropped_database import RestorableDroppedDatabase
Expand Down Expand Up @@ -275,6 +278,7 @@
from .managed_database_security_alert_policy import ManagedDatabaseSecurityAlertPolicy
from .managed_server_security_alert_policy import ManagedServerSecurityAlertPolicy
from .sensitivity_label import SensitivityLabel
from .managed_instance_administrator import ManagedInstanceAdministrator
from .database_operation import DatabaseOperation
from .elastic_pool_operation import ElasticPoolOperation
from .max_size_capability import MaxSizeCapability
Expand Down Expand Up @@ -321,6 +325,8 @@
from .usage import Usage
from .managed_instance import ManagedInstance
from .managed_instance_update import ManagedInstanceUpdate
from .private_link_resource_properties import PrivateLinkResourceProperties
from .private_link_resource import PrivateLinkResource
from .recoverable_database_paged import RecoverableDatabasePaged
from .restorable_dropped_database_paged import RestorableDroppedDatabasePaged
from .server_paged import ServerPaged
Expand Down Expand Up @@ -375,6 +381,7 @@
from .managed_database_security_alert_policy_paged import ManagedDatabaseSecurityAlertPolicyPaged
from .managed_server_security_alert_policy_paged import ManagedServerSecurityAlertPolicyPaged
from .sensitivity_label_paged import SensitivityLabelPaged
from .managed_instance_administrator_paged import ManagedInstanceAdministratorPaged
from .database_operation_paged import DatabaseOperationPaged
from .elastic_pool_operation_paged import ElasticPoolOperationPaged
from .vulnerability_assessment_scan_record_paged import VulnerabilityAssessmentScanRecordPaged
Expand All @@ -388,6 +395,7 @@
from .instance_pool_paged import InstancePoolPaged
from .usage_paged import UsagePaged
from .managed_instance_paged import ManagedInstancePaged
from .private_link_resource_paged import PrivateLinkResourcePaged
from .sql_management_client_enums import (
CheckNameAvailabilityReason,
ServerConnectionType,
Expand Down Expand Up @@ -582,6 +590,7 @@
'ManagedDatabaseSecurityAlertPolicy',
'ManagedServerSecurityAlertPolicy',
'SensitivityLabel',
'ManagedInstanceAdministrator',
'DatabaseOperation',
'ElasticPoolOperation',
'MaxSizeCapability',
Expand Down Expand Up @@ -628,6 +637,8 @@
'Usage',
'ManagedInstance',
'ManagedInstanceUpdate',
'PrivateLinkResourceProperties',
'PrivateLinkResource',
'RecoverableDatabasePaged',
'RestorableDroppedDatabasePaged',
'ServerPaged',
Expand Down Expand Up @@ -682,6 +693,7 @@
'ManagedDatabaseSecurityAlertPolicyPaged',
'ManagedServerSecurityAlertPolicyPaged',
'SensitivityLabelPaged',
'ManagedInstanceAdministratorPaged',
'DatabaseOperationPaged',
'ElasticPoolOperationPaged',
'VulnerabilityAssessmentScanRecordPaged',
Expand All @@ -695,6 +707,7 @@
'InstancePoolPaged',
'UsagePaged',
'ManagedInstancePaged',
'PrivateLinkResourcePaged',
'CheckNameAvailabilityReason',
'ServerConnectionType',
'SecurityAlertPolicyState',
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
# 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 .proxy_resource import ProxyResource


class ManagedInstanceAdministrator(ProxyResource):
"""An Azure SQL managed instance administrator.

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: Resource ID.
:vartype id: str
:ivar name: Resource name.
:vartype name: str
:ivar type: Resource type.
:vartype type: str
:ivar administrator_type: Required. Type of the managed instance
administrator. Default value: "ActiveDirectory" .
:vartype administrator_type: str
:param login: Required. Login name of the managed instance administrator.
:type login: str
:param sid: Required. SID (object ID) of the managed instance
administrator.
:type sid: str
:param tenant_id: Tenant ID of the managed instance administrator.
:type tenant_id: str
"""

_validation = {
'id': {'readonly': True},
'name': {'readonly': True},
'type': {'readonly': True},
'administrator_type': {'required': True, 'constant': True},
'login': {'required': True},
'sid': {'required': True},
}

_attribute_map = {
'id': {'key': 'id', 'type': 'str'},
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'administrator_type': {'key': 'properties.administratorType', 'type': 'str'},
'login': {'key': 'properties.login', 'type': 'str'},
'sid': {'key': 'properties.sid', 'type': 'str'},
'tenant_id': {'key': 'properties.tenantId', 'type': 'str'},
}

administrator_type = "ActiveDirectory"

def __init__(self, **kwargs):
super(ManagedInstanceAdministrator, self).__init__(**kwargs)
self.login = kwargs.get('login', None)
self.sid = kwargs.get('sid', None)
self.tenant_id = kwargs.get('tenant_id', None)
Original file line number Diff line number Diff line change
@@ -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 ManagedInstanceAdministratorPaged(Paged):
"""
A paging container for iterating over a list of :class:`ManagedInstanceAdministrator <azure.mgmt.sql.models.ManagedInstanceAdministrator>` object
"""

_attribute_map = {
'next_link': {'key': 'nextLink', 'type': 'str'},
'current_page': {'key': 'value', 'type': '[ManagedInstanceAdministrator]'}
}

def __init__(self, *args, **kwargs):

super(ManagedInstanceAdministratorPaged, self).__init__(*args, **kwargs)
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
# 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 .proxy_resource_py3 import ProxyResource


class ManagedInstanceAdministrator(ProxyResource):
"""An Azure SQL managed instance administrator.

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: Resource ID.
:vartype id: str
:ivar name: Resource name.
:vartype name: str
:ivar type: Resource type.
:vartype type: str
:ivar administrator_type: Required. Type of the managed instance
administrator. Default value: "ActiveDirectory" .
:vartype administrator_type: str
:param login: Required. Login name of the managed instance administrator.
:type login: str
:param sid: Required. SID (object ID) of the managed instance
administrator.
:type sid: str
:param tenant_id: Tenant ID of the managed instance administrator.
:type tenant_id: str
"""

_validation = {
'id': {'readonly': True},
'name': {'readonly': True},
'type': {'readonly': True},
'administrator_type': {'required': True, 'constant': True},
'login': {'required': True},
'sid': {'required': True},
}

_attribute_map = {
'id': {'key': 'id', 'type': 'str'},
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'administrator_type': {'key': 'properties.administratorType', 'type': 'str'},
'login': {'key': 'properties.login', 'type': 'str'},
'sid': {'key': 'properties.sid', 'type': 'str'},
'tenant_id': {'key': 'properties.tenantId', 'type': 'str'},
}

administrator_type = "ActiveDirectory"

def __init__(self, *, login: str, sid: str, tenant_id: str=None, **kwargs) -> None:
super(ManagedInstanceAdministrator, self).__init__(**kwargs)
self.login = login
self.sid = sid
self.tenant_id = tenant_id
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# 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 .proxy_resource import ProxyResource


class PrivateLinkResource(ProxyResource):
"""A private link resource.

Variables are only populated by the server, and will be ignored when
sending a request.

:ivar id: Resource ID.
:vartype id: str
:ivar name: Resource name.
:vartype name: str
:ivar type: Resource type.
:vartype type: str
:ivar properties: The private link resource group id.
:vartype properties: ~azure.mgmt.sql.models.PrivateLinkResourceProperties
"""

_validation = {
'id': {'readonly': True},
'name': {'readonly': True},
'type': {'readonly': True},
'properties': {'readonly': True},
}

_attribute_map = {
'id': {'key': 'id', 'type': 'str'},
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'properties': {'key': 'properties', 'type': 'PrivateLinkResourceProperties'},
}

def __init__(self, **kwargs):
super(PrivateLinkResource, self).__init__(**kwargs)
self.properties = None
Original file line number Diff line number Diff line change
@@ -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 PrivateLinkResourcePaged(Paged):
"""
A paging container for iterating over a list of :class:`PrivateLinkResource <azure.mgmt.sql.models.PrivateLinkResource>` object
"""

_attribute_map = {
'next_link': {'key': 'nextLink', 'type': 'str'},
'current_page': {'key': 'value', 'type': '[PrivateLinkResource]'}
}

def __init__(self, *args, **kwargs):

super(PrivateLinkResourcePaged, self).__init__(*args, **kwargs)
Original file line number Diff line number Diff line change
@@ -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 PrivateLinkResourceProperties(Model):
"""Properties of a private link resource.

Variables are only populated by the server, and will be ignored when
sending a request.

:ivar group_id: The private link resource group id.
:vartype group_id: str
:ivar required_members: The private link resource required member names.
:vartype required_members: list[str]
"""

_validation = {
'group_id': {'readonly': True},
'required_members': {'readonly': True},
}

_attribute_map = {
'group_id': {'key': 'groupId', 'type': 'str'},
'required_members': {'key': 'requiredMembers', 'type': '[str]'},
}

def __init__(self, **kwargs):
super(PrivateLinkResourceProperties, self).__init__(**kwargs)
self.group_id = None
self.required_members = None
Loading