# 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::Hdinsight::Mgmt::V2018_06_01_preview
  module Models
    #
    # Describes a role on the cluster.
    #
    class Role

      include MsRestAzure

      # @return [String] The name of the role.
      attr_accessor :name

      # @return [Integer] The minimum instance count of the cluster.
      attr_accessor :min_instance_count

      # @return [Integer] The instance count of the cluster.
      attr_accessor :target_instance_count

      # @return [String] The name of the virtual machine group.
      attr_accessor :vmgroup_name

      # @return [Autoscale] The autoscale configurations.
      attr_accessor :autoscale_configuration

      # @return [HardwareProfile] The hardware profile.
      attr_accessor :hardware_profile

      # @return [OsProfile] The operating system profile.
      attr_accessor :os_profile

      # @return [VirtualNetworkProfile] The virtual network profile.
      attr_accessor :virtual_network_profile

      # @return [Array<DataDisksGroups>] The data disks groups for the role.
      attr_accessor :data_disks_groups

      # @return [Array<ScriptAction>] The list of script actions on the role.
      attr_accessor :script_actions

      # @return [Boolean] Indicates whether encrypt the data disks.
      attr_accessor :encrypt_data_disks


      #
      # Mapper for Role class as Ruby Hash.
      # This will be used for serialization/deserialization.
      #
      def self.mapper()
        {
          client_side_validation: true,
          required: false,
          serialized_name: 'Role',
          type: {
            name: 'Composite',
            class_name: 'Role',
            model_properties: {
              name: {
                client_side_validation: true,
                required: false,
                serialized_name: 'name',
                type: {
                  name: 'String'
                }
              },
              min_instance_count: {
                client_side_validation: true,
                required: false,
                serialized_name: 'minInstanceCount',
                type: {
                  name: 'Number'
                }
              },
              target_instance_count: {
                client_side_validation: true,
                required: false,
                serialized_name: 'targetInstanceCount',
                type: {
                  name: 'Number'
                }
              },
              vmgroup_name: {
                client_side_validation: true,
                required: false,
                serialized_name: 'VMGroupName',
                type: {
                  name: 'String'
                }
              },
              autoscale_configuration: {
                client_side_validation: true,
                required: false,
                serialized_name: 'autoscale',
                type: {
                  name: 'Composite',
                  class_name: 'Autoscale'
                }
              },
              hardware_profile: {
                client_side_validation: true,
                required: false,
                serialized_name: 'hardwareProfile',
                type: {
                  name: 'Composite',
                  class_name: 'HardwareProfile'
                }
              },
              os_profile: {
                client_side_validation: true,
                required: false,
                serialized_name: 'osProfile',
                type: {
                  name: 'Composite',
                  class_name: 'OsProfile'
                }
              },
              virtual_network_profile: {
                client_side_validation: true,
                required: false,
                serialized_name: 'virtualNetworkProfile',
                type: {
                  name: 'Composite',
                  class_name: 'VirtualNetworkProfile'
                }
              },
              data_disks_groups: {
                client_side_validation: true,
                required: false,
                serialized_name: 'dataDisksGroups',
                type: {
                  name: 'Sequence',
                  element: {
                      client_side_validation: true,
                      required: false,
                      serialized_name: 'DataDisksGroupsElementType',
                      type: {
                        name: 'Composite',
                        class_name: 'DataDisksGroups'
                      }
                  }
                }
              },
              script_actions: {
                client_side_validation: true,
                required: false,
                serialized_name: 'scriptActions',
                type: {
                  name: 'Sequence',
                  element: {
                      client_side_validation: true,
                      required: false,
                      serialized_name: 'ScriptActionElementType',
                      type: {
                        name: 'Composite',
                        class_name: 'ScriptAction'
                      }
                  }
                }
              },
              encrypt_data_disks: {
                client_side_validation: true,
                required: false,
                serialized_name: 'encryptDataDisks',
                type: {
                  name: 'Boolean'
                }
              }
            }
          }
        }
      end
    end
  end
end
