# 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::WebSearch::V1_0
  module Models
    #
    # Defines the data and time of one or more geographic locations.
    #
    class TimeZone < SearchResultsAnswer

      include MsRestAzure


      def initialize
        @_type = "TimeZone"
      end

      attr_accessor :_type

      # @return [TimeZoneTimeZoneInformation] The data and time, in UTC, of the
      # geographic location specified in the query. If the query specified a
      # specific geographic location (for example, a city), this object
      # contains the name of the geographic location and the current date and
      # time of the location, in UTC. If the query specified a general
      # geographic location, such as a state or country, this object contains
      # the date and time of the primary city or state found in the specified
      # state or country. If the location contains additional time zones, the
      # otherCityTimes field contains the data and time of cities or states
      # located in the other time zones.
      attr_accessor :primary_city_time

      # @return [Array<TimeZoneTimeZoneInformation>] A list of dates and times
      # of nearby time zones.
      attr_accessor :other_city_times


      #
      # Mapper for TimeZone class as Ruby Hash.
      # This will be used for serialization/deserialization.
      #
      def self.mapper()
        {
          client_side_validation: true,
          required: false,
          serialized_name: 'TimeZone',
          type: {
            name: 'Composite',
            class_name: 'TimeZone',
            model_properties: {
              _type: {
                client_side_validation: true,
                required: true,
                serialized_name: '_type',
                type: {
                  name: 'String'
                }
              },
              id: {
                client_side_validation: true,
                required: false,
                read_only: true,
                serialized_name: 'id',
                type: {
                  name: 'String'
                }
              },
              web_search_url: {
                client_side_validation: true,
                required: false,
                read_only: true,
                serialized_name: 'webSearchUrl',
                type: {
                  name: 'String'
                }
              },
              follow_up_queries: {
                client_side_validation: true,
                required: false,
                read_only: true,
                serialized_name: 'followUpQueries',
                type: {
                  name: 'Sequence',
                  element: {
                      client_side_validation: true,
                      required: false,
                      serialized_name: 'QueryElementType',
                      type: {
                        name: 'Composite',
                        class_name: 'Query'
                      }
                  }
                }
              },
              query_context: {
                client_side_validation: true,
                required: false,
                read_only: true,
                serialized_name: 'queryContext',
                type: {
                  name: 'Composite',
                  class_name: 'QueryContext'
                }
              },
              total_estimated_matches: {
                client_side_validation: true,
                required: false,
                read_only: true,
                serialized_name: 'totalEstimatedMatches',
                type: {
                  name: 'Number'
                }
              },
              is_family_friendly: {
                client_side_validation: true,
                required: false,
                read_only: true,
                serialized_name: 'isFamilyFriendly',
                type: {
                  name: 'Boolean'
                }
              },
              primary_city_time: {
                client_side_validation: true,
                required: true,
                serialized_name: 'primaryCityTime',
                type: {
                  name: 'Composite',
                  class_name: 'TimeZoneTimeZoneInformation'
                }
              },
              other_city_times: {
                client_side_validation: true,
                required: false,
                read_only: true,
                serialized_name: 'otherCityTimes',
                type: {
                  name: 'Sequence',
                  element: {
                      client_side_validation: true,
                      required: false,
                      serialized_name: 'TimeZoneTimeZoneInformationElementType',
                      type: {
                        name: 'Composite',
                        class_name: 'TimeZoneTimeZoneInformation'
                      }
                  }
                }
              }
            }
          }
        }
      end
    end
  end
end
