# 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::SQL::Mgmt::V2015_05_01_preview
  module Models
    #
    # Contains error information for an Azure SQL Database, Server or Elastic
    # Pool Recommended Action.
    #
    class RecommendedActionErrorInfo

      include MsRestAzure

      # @return [String] Gets the reason why the recommended action was put to
      # error state. e.g., DatabaseHasQdsOff, IndexAlreadyExists
      attr_accessor :error_code

      # @return [IsRetryable] Gets whether the error could be ignored and
      # recommended action could be retried. Possible values are: Yes/No.
      # Possible values include: 'Yes', 'No'
      attr_accessor :is_retryable


      #
      # Mapper for RecommendedActionErrorInfo class as Ruby Hash.
      # This will be used for serialization/deserialization.
      #
      def self.mapper()
        {
          client_side_validation: true,
          required: false,
          serialized_name: 'RecommendedActionErrorInfo',
          type: {
            name: 'Composite',
            class_name: 'RecommendedActionErrorInfo',
            model_properties: {
              error_code: {
                client_side_validation: true,
                required: false,
                read_only: true,
                serialized_name: 'errorCode',
                type: {
                  name: 'String'
                }
              },
              is_retryable: {
                client_side_validation: true,
                required: false,
                read_only: true,
                serialized_name: 'isRetryable',
                type: {
                  name: 'Enum',
                  module: 'IsRetryable'
                }
              }
            }
          }
        }
      end
    end
  end
end
