Skip to content
Prev Previous commit
Generated from 23f4c95562b46fa4d5639c5320769bc149818363 (#6630)
Add managedInstaceAdministrators.json to readme file, which reprepresents AutoRest configuration file for Sql
  • Loading branch information
AutorestCI authored Aug 15, 2019
commit ca9e324c52d3184d8a148624c3d92226cffb1667
5 changes: 5 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 @@ -275,6 +276,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 @@ -375,6 +377,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 Down Expand Up @@ -582,6 +585,7 @@
'ManagedDatabaseSecurityAlertPolicy',
'ManagedServerSecurityAlertPolicy',
'SensitivityLabel',
'ManagedInstanceAdministrator',
'DatabaseOperation',
'ElasticPoolOperation',
'MaxSizeCapability',
Expand Down Expand Up @@ -682,6 +686,7 @@
'ManagedDatabaseSecurityAlertPolicyPaged',
'ManagedServerSecurityAlertPolicyPaged',
'SensitivityLabelPaged',
'ManagedInstanceAdministratorPaged',
'DatabaseOperationPaged',
'ElasticPoolOperationPaged',
'VulnerabilityAssessmentScanRecordPaged',
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
2 changes: 2 additions & 0 deletions sdk/sql/azure-mgmt-sql/azure/mgmt/sql/operations/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@
from .managed_database_security_alert_policies_operations import ManagedDatabaseSecurityAlertPoliciesOperations
from .managed_server_security_alert_policies_operations import ManagedServerSecurityAlertPoliciesOperations
from .sensitivity_labels_operations import SensitivityLabelsOperations
from .managed_instance_administrators_operations import ManagedInstanceAdministratorsOperations
from .database_operations import DatabaseOperations
from .elastic_pool_operations import ElasticPoolOperations
from .capabilities_operations import CapabilitiesOperations
Expand Down Expand Up @@ -155,6 +156,7 @@
'ManagedDatabaseSecurityAlertPoliciesOperations',
'ManagedServerSecurityAlertPoliciesOperations',
'SensitivityLabelsOperations',
'ManagedInstanceAdministratorsOperations',
'DatabaseOperations',
'ElasticPoolOperations',
'CapabilitiesOperations',
Expand Down
Loading