# encoding: utf-8
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.

module Azure::ResourcesManagement::Mgmt::V2017_11_01_preview
  module Models
    #
    # The child information of a management group.
    #
    class ManagementGroupChildInfo

      include MsRestAzure

      # @return [Enum] The type of child resource. Possible values include:
      # 'ManagementGroup', 'Subscription'
      attr_accessor :child_type

      # @return [String] The fully qualified ID for the child resource
      # (management group or subscription).  For example,
      # /providers/Microsoft.Management/managementGroups/0000000-0000-0000-0000-000000000000
      attr_accessor :child_id

      # @return [String] The friendly name of the child resource.
      attr_accessor :display_name

      # @return [Array<ManagementGroupChildInfo>] The list of children.
      attr_accessor :children


      #
      # Mapper for ManagementGroupChildInfo class as Ruby Hash.
      # This will be used for serialization/deserialization.
      #
      def self.mapper()
        {
          client_side_validation: true,
          required: false,
          serialized_name: 'ManagementGroupChildInfo',
          type: {
            name: 'Composite',
            class_name: 'ManagementGroupChildInfo',
            model_properties: {
              child_type: {
                client_side_validation: true,
                required: false,
                serialized_name: 'childType',
                type: {
                  name: 'String'
                }
              },
              child_id: {
                client_side_validation: true,
                required: false,
                serialized_name: 'childId',
                type: {
                  name: 'String'
                }
              },
              display_name: {
                client_side_validation: true,
                required: false,
                serialized_name: 'displayName',
                type: {
                  name: 'String'
                }
              },
              children: {
                client_side_validation: true,
                required: false,
                serialized_name: 'children',
                type: {
                  name: 'Sequence',
                  element: {
                      client_side_validation: true,
                      required: false,
                      serialized_name: 'ManagementGroupChildInfoElementType',
                      type: {
                        name: 'Composite',
                        class_name: 'ManagementGroupChildInfo'
                      }
                  }
                }
              }
            }
          }
        }
      end
    end
  end
end
