# 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::CognitiveServices::EntitySearch::V1_0
  module Models
    #
    # Model object.
    #
    #
    class ContractualRulesAttribution < ContractualRulesContractualRule

      include MsRestAzure


      def initialize
        @_type = "ContractualRules/Attribution"
      end

      attr_accessor :_type

      # @return [Boolean] A Boolean value that determines whether the contents
      # of the rule must be placed in close proximity to the field that the
      # rule applies to. If true, the contents must be placed in close
      # proximity. If false, or this field does not exist, the contents may be
      # placed at the caller's discretion.
      attr_accessor :must_be_close_to_content


      #
      # Mapper for ContractualRulesAttribution class as Ruby Hash.
      # This will be used for serialization/deserialization.
      #
      def self.mapper()
        {
          client_side_validation: true,
          required: false,
          serialized_name: 'ContractualRules/Attribution',
          type: {
            name: 'Composite',
            class_name: 'ContractualRulesAttribution',
            model_properties: {
              target_property_name: {
                client_side_validation: true,
                required: false,
                read_only: true,
                serialized_name: 'targetPropertyName',
                type: {
                  name: 'String'
                }
              },
              _type: {
                client_side_validation: true,
                required: true,
                serialized_name: '_type',
                type: {
                  name: 'String'
                }
              },
              must_be_close_to_content: {
                client_side_validation: true,
                required: false,
                read_only: true,
                serialized_name: 'mustBeCloseToContent',
                type: {
                  name: 'Boolean'
                }
              }
            }
          }
        }
      end
    end
  end
end
