# coding=utf-8
# --------------------------------------------------------------------------
# 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 AdiEmsWebApiV2DtoSchemaFieldGroup(Model):
    """Represents a folder in the data source tree of an EMS installation.

    All required parameters must be populated in order to send to Azure.

    :param id: Required. The unique string identifier for the field group
    :type id: str
    :param name: Required. The display name for the field group
    :type name: str
    :param groups: An ordered list of child groups contained in a field group
    :type groups: list[~emsapi.models.AdiEmsWebApiV2DtoSchemaFieldGroup]
    :param fields: An ordered list of child fields contained in a field group
    :type fields: list[~emsapi.models.AdiEmsWebApiV2DtoSchemaField]
    """

    _validation = {
        'id': {'required': True},
        'name': {'required': True},
    }

    _attribute_map = {
        'id': {'key': 'id', 'type': 'str'},
        'name': {'key': 'name', 'type': 'str'},
        'groups': {'key': 'groups', 'type': '[AdiEmsWebApiV2DtoSchemaFieldGroup]'},
        'fields': {'key': 'fields', 'type': '[AdiEmsWebApiV2DtoSchemaField]'},
    }

    def __init__(self, **kwargs):
        super(AdiEmsWebApiV2DtoSchemaFieldGroup, self).__init__(**kwargs)
        self.id = kwargs.get('id', None)
        self.name = kwargs.get('name', None)
        self.groups = kwargs.get('groups', None)
        self.fields = kwargs.get('fields', None)
