build

in lib/facebook_ads/ad_objects/server_side/event.rb [129:179]


      def build(attributes = {})
        return unless attributes.is_a?(Hash)

        
        attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }

        if attributes.has_key?(:'event_name')
          self.event_name = attributes[:'event_name']
        end

        if attributes.has_key?(:'event_time')
          self.event_time = attributes[:'event_time']
        end

        if attributes.has_key?(:'event_source_url')
          self.event_source_url = attributes[:'event_source_url']
        end

        if attributes.has_key?(:'opt_out')
          self.opt_out = attributes[:'opt_out']
        end

        if attributes.has_key?(:'event_id')
          self.event_id = attributes[:'event_id']
        end

        if attributes.has_key?(:'user_data')
          self.user_data = attributes[:'user_data']
        end

        if attributes.has_key?(:'custom_data')
          self.custom_data = attributes[:'custom_data']
        end

        if attributes.has_key?(:'data_processing_options')
          self.data_processing_options = attributes[:'data_processing_options']
        end

        if attributes.has_key?(:'data_processing_options_country')
          self.data_processing_options_country = attributes[:'data_processing_options_country']
        end

        if attributes.has_key?(:'data_processing_options_state')
          self.data_processing_options_state = attributes[:'data_processing_options_state']
        end

        if attributes.has_key?(:'action_source')
          self.action_source = attributes[:'action_source']
        end
      end