// third_party/blink/public/mojom/webpreferences/web_preferences.mojom.cc is auto generated by mojom_bindings_generator.py, do not edit

// Copyright 2013 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#if defined(__clang__)
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wunused-private-field"
#endif

#include "third_party/blink/public/mojom/webpreferences/web_preferences.mojom.h"

#include <math.h>
#include <stdint.h>
#include <utility>

#include "base/hash/md5_constexpr.h"
#include "base/run_loop.h"
#include "base/strings/string_number_conversions.h"
#include "base/task/common/task_annotator.h"
#include "base/trace_event/trace_conversion_helper.h"
#include "base/trace_event/traced_value.h"
#include "mojo/public/cpp/bindings/lib/generated_code_util.h"
#include "mojo/public/cpp/bindings/lib/message_internal.h"
#include "mojo/public/cpp/bindings/lib/serialization_util.h"
#include "mojo/public/cpp/bindings/lib/unserialized_message_context.h"
#include "mojo/public/cpp/bindings/lib/validate_params.h"
#include "mojo/public/cpp/bindings/lib/validation_context.h"
#include "mojo/public/cpp/bindings/lib/validation_errors.h"
#include "mojo/public/interfaces/bindings/interface_control_messages.mojom.h"

#include "third_party/blink/public/mojom/webpreferences/web_preferences.mojom-params-data.h"
#include "third_party/blink/public/mojom/webpreferences/web_preferences.mojom-shared-message-ids.h"

#include "third_party/blink/public/mojom/webpreferences/web_preferences.mojom-import-headers.h"


#ifndef THIRD_PARTY_BLINK_PUBLIC_MOJOM_WEBPREFERENCES_WEB_PREFERENCES_MOJOM_JUMBO_H_
#define THIRD_PARTY_BLINK_PUBLIC_MOJOM_WEBPREFERENCES_WEB_PREFERENCES_MOJOM_JUMBO_H_
#endif
namespace blink {
namespace mojom {
WebPreferences::WebPreferences()
    : standard_font_family_map(),
      fixed_font_family_map(),
      serif_font_family_map(),
      sans_serif_font_family_map(),
      cursive_font_family_map(),
      fantasy_font_family_map(),
      pictograph_font_family_map(),
      default_font_size(),
      default_fixed_font_size(),
      minimum_font_size(),
      minimum_logical_font_size(),
      default_encoding(),
      context_menu_on_mouse_up(),
      javascript_enabled(),
      web_security_enabled(),
      loads_images_automatically(),
      images_enabled(),
      plugins_enabled(),
      dom_paste_enabled(),
      shrinks_standalone_images_to_fit(),
      text_areas_are_resizable(),
      allow_scripts_to_close_windows(),
      remote_fonts_enabled(),
      javascript_can_access_clipboard(),
      xslt_enabled(),
      dns_prefetching_enabled(),
      data_saver_enabled(),
      data_saver_holdback_web_api_enabled(),
      local_storage_enabled(),
      databases_enabled(),
      application_cache_enabled(),
      tabs_to_links(),
      disable_ipc_flooding_protection(),
      hyperlink_auditing_enabled(),
      allow_universal_access_from_file_urls(),
      allow_file_access_from_file_urls(),
      webgl1_enabled(),
      webgl2_enabled(),
      pepper_3d_enabled(),
      flash_3d_enabled(),
      flash_stage3d_enabled(),
      flash_stage3d_baseline_enabled(),
      privileged_webgl_extensions_enabled(),
      webgl_errors_to_console_enabled(),
      hide_scrollbars(),
      accelerated_2d_canvas_enabled(),
      new_canvas_2d_api_enabled(),
      antialiased_2d_canvas_disabled(),
      antialiased_clips_2d_canvas_enabled(),
      accelerated_filters_enabled(),
      deferred_filters_enabled(),
      container_culling_enabled(),
      allow_running_insecure_content(),
      disable_reading_from_canvas(),
      strict_mixed_content_checking(),
      strict_powerful_feature_restrictions(),
      allow_geolocation_on_insecure_origins(),
      strictly_block_blockable_mixed_content(),
      block_mixed_plugin_content(),
      password_echo_enabled(),
      should_clear_document_background(),
      enable_scroll_animator(),
      prefers_reduced_motion(),
      touch_event_feature_detection_enabled(),
      enable_error_page(),
      pointer_events_max_touch_points(),
      available_pointer_types(),
      primary_pointer_type(),
      available_hover_types(),
      primary_hover_type(),
      dont_send_key_events_to_javascript(),
      barrel_button_for_drag_enabled(),
      sync_xhr_in_documents_enabled(),
      number_of_cpu_cores(),
      editing_behavior(),
      supports_multiple_windows(),
      viewport_enabled(),
      viewport_meta_enabled(),
      shrinks_viewport_contents_to_fit(),
      viewport_style(),
      smooth_scroll_for_find_enabled(),
      main_frame_resizes_are_orientation_changes(),
      initialize_at_minimum_page_scale(),
      smart_insert_delete_enabled(),
      spatial_navigation_enabled(),
      navigate_on_drag_drop(),
      v8_cache_options(),
      record_whole_document(),
      cookie_enabled(),
      accelerated_video_decode_enabled(),
      animation_policy(),
      user_gesture_required_for_presentation(),
      text_tracks_enabled(),
      text_track_background_color(),
      text_track_text_color(),
      text_track_text_size(),
      text_track_text_shadow(),
      text_track_font_family(),
      text_track_font_style(),
      text_track_font_variant(),
      text_track_window_color(),
      text_track_window_padding(),
      text_track_window_radius(),
      text_track_margin_percentage(),
      immersive_mode_enabled(),
      double_tap_to_zoom_enabled(),
      fullscreen_supported(),
      text_autosizing_enabled(),
      web_app_scope(),
      force_dark_mode_enabled(),
      default_minimum_page_scale_factor(),
      default_maximum_page_scale_factor(),
      hide_download_ui(),
      presentation_receiver(),
      media_controls_enabled(),
      do_not_update_selection_on_mutating_selection_range(),
      autoplay_policy(),
      preferred_color_scheme(),
      low_priority_iframes_threshold(),
      picture_in_picture_enabled(),
      translate_service_available(),
      network_quality_estimator_web_holdback(),
      lazy_load_enabled(),
      lazy_frame_loading_distance_thresholds_px(),
      lazy_image_loading_distance_thresholds_px(),
      lazy_image_first_k_fully_load(),
      allow_mixed_content_upgrades(),
      always_show_focus(),
      touch_drag_drop_enabled() {}

WebPreferences::WebPreferences(
    const base::flat_map<std::string, ::base::string16>& standard_font_family_map_in,
    const base::flat_map<std::string, ::base::string16>& fixed_font_family_map_in,
    const base::flat_map<std::string, ::base::string16>& serif_font_family_map_in,
    const base::flat_map<std::string, ::base::string16>& sans_serif_font_family_map_in,
    const base::flat_map<std::string, ::base::string16>& cursive_font_family_map_in,
    const base::flat_map<std::string, ::base::string16>& fantasy_font_family_map_in,
    const base::flat_map<std::string, ::base::string16>& pictograph_font_family_map_in,
    int32_t default_font_size_in,
    int32_t default_fixed_font_size_in,
    int32_t minimum_font_size_in,
    int32_t minimum_logical_font_size_in,
    const std::string& default_encoding_in,
    bool context_menu_on_mouse_up_in,
    bool javascript_enabled_in,
    bool web_security_enabled_in,
    bool loads_images_automatically_in,
    bool images_enabled_in,
    bool plugins_enabled_in,
    bool dom_paste_enabled_in,
    bool shrinks_standalone_images_to_fit_in,
    bool text_areas_are_resizable_in,
    bool allow_scripts_to_close_windows_in,
    bool remote_fonts_enabled_in,
    bool javascript_can_access_clipboard_in,
    bool xslt_enabled_in,
    bool dns_prefetching_enabled_in,
    bool data_saver_enabled_in,
    bool data_saver_holdback_web_api_enabled_in,
    bool local_storage_enabled_in,
    bool databases_enabled_in,
    bool application_cache_enabled_in,
    bool tabs_to_links_in,
    bool disable_ipc_flooding_protection_in,
    bool hyperlink_auditing_enabled_in,
    bool allow_universal_access_from_file_urls_in,
    bool allow_file_access_from_file_urls_in,
    bool webgl1_enabled_in,
    bool webgl2_enabled_in,
    bool pepper_3d_enabled_in,
    bool flash_3d_enabled_in,
    bool flash_stage3d_enabled_in,
    bool flash_stage3d_baseline_enabled_in,
    bool privileged_webgl_extensions_enabled_in,
    bool webgl_errors_to_console_enabled_in,
    bool hide_scrollbars_in,
    bool accelerated_2d_canvas_enabled_in,
    bool new_canvas_2d_api_enabled_in,
    bool antialiased_2d_canvas_disabled_in,
    bool antialiased_clips_2d_canvas_enabled_in,
    bool accelerated_filters_enabled_in,
    bool deferred_filters_enabled_in,
    bool container_culling_enabled_in,
    bool allow_running_insecure_content_in,
    bool disable_reading_from_canvas_in,
    bool strict_mixed_content_checking_in,
    bool strict_powerful_feature_restrictions_in,
    bool allow_geolocation_on_insecure_origins_in,
    bool strictly_block_blockable_mixed_content_in,
    bool block_mixed_plugin_content_in,
    bool password_echo_enabled_in,
    bool should_clear_document_background_in,
    bool enable_scroll_animator_in,
    bool prefers_reduced_motion_in,
    bool touch_event_feature_detection_enabled_in,
    bool enable_error_page_in,
    int32_t pointer_events_max_touch_points_in,
    int32_t available_pointer_types_in,
    PointerType primary_pointer_type_in,
    int32_t available_hover_types_in,
    HoverType primary_hover_type_in,
    bool dont_send_key_events_to_javascript_in,
    bool barrel_button_for_drag_enabled_in,
    bool sync_xhr_in_documents_enabled_in,
    int32_t number_of_cpu_cores_in,
    EditingBehavior editing_behavior_in,
    bool supports_multiple_windows_in,
    bool viewport_enabled_in,
    bool viewport_meta_enabled_in,
    bool shrinks_viewport_contents_to_fit_in,
    ViewportStyle viewport_style_in,
    bool smooth_scroll_for_find_enabled_in,
    bool main_frame_resizes_are_orientation_changes_in,
    bool initialize_at_minimum_page_scale_in,
    bool smart_insert_delete_enabled_in,
    bool spatial_navigation_enabled_in,
    bool navigate_on_drag_drop_in,
    ::blink::mojom::V8CacheOptions v8_cache_options_in,
    bool record_whole_document_in,
    bool cookie_enabled_in,
    bool accelerated_video_decode_enabled_in,
    ImageAnimationPolicy animation_policy_in,
    bool user_gesture_required_for_presentation_in,
    bool text_tracks_enabled_in,
    const std::string& text_track_background_color_in,
    const std::string& text_track_text_color_in,
    const std::string& text_track_text_size_in,
    const std::string& text_track_text_shadow_in,
    const std::string& text_track_font_family_in,
    const std::string& text_track_font_style_in,
    const std::string& text_track_font_variant_in,
    const std::string& text_track_window_color_in,
    const std::string& text_track_window_padding_in,
    const std::string& text_track_window_radius_in,
    float text_track_margin_percentage_in,
    bool immersive_mode_enabled_in,
    bool double_tap_to_zoom_enabled_in,
    bool fullscreen_supported_in,
    bool text_autosizing_enabled_in,
    const ::GURL& web_app_scope_in,
    bool force_dark_mode_enabled_in,
    float default_minimum_page_scale_factor_in,
    float default_maximum_page_scale_factor_in,
    bool hide_download_ui_in,
    bool presentation_receiver_in,
    bool media_controls_enabled_in,
    bool do_not_update_selection_on_mutating_selection_range_in,
    AutoplayPolicy autoplay_policy_in,
    PreferredColorScheme preferred_color_scheme_in,
    EffectiveConnectionType low_priority_iframes_threshold_in,
    bool picture_in_picture_enabled_in,
    bool translate_service_available_in,
    EffectiveConnectionType network_quality_estimator_web_holdback_in,
    bool lazy_load_enabled_in,
    const base::flat_map<EffectiveConnectionType, int32_t>& lazy_frame_loading_distance_thresholds_px_in,
    const base::flat_map<EffectiveConnectionType, int32_t>& lazy_image_loading_distance_thresholds_px_in,
    const base::flat_map<EffectiveConnectionType, int32_t>& lazy_image_first_k_fully_load_in,
    bool allow_mixed_content_upgrades_in,
    bool always_show_focus_in,
    bool touch_drag_drop_enabled_in)
    : standard_font_family_map(std::move(standard_font_family_map_in)),
      fixed_font_family_map(std::move(fixed_font_family_map_in)),
      serif_font_family_map(std::move(serif_font_family_map_in)),
      sans_serif_font_family_map(std::move(sans_serif_font_family_map_in)),
      cursive_font_family_map(std::move(cursive_font_family_map_in)),
      fantasy_font_family_map(std::move(fantasy_font_family_map_in)),
      pictograph_font_family_map(std::move(pictograph_font_family_map_in)),
      default_font_size(std::move(default_font_size_in)),
      default_fixed_font_size(std::move(default_fixed_font_size_in)),
      minimum_font_size(std::move(minimum_font_size_in)),
      minimum_logical_font_size(std::move(minimum_logical_font_size_in)),
      default_encoding(std::move(default_encoding_in)),
      context_menu_on_mouse_up(std::move(context_menu_on_mouse_up_in)),
      javascript_enabled(std::move(javascript_enabled_in)),
      web_security_enabled(std::move(web_security_enabled_in)),
      loads_images_automatically(std::move(loads_images_automatically_in)),
      images_enabled(std::move(images_enabled_in)),
      plugins_enabled(std::move(plugins_enabled_in)),
      dom_paste_enabled(std::move(dom_paste_enabled_in)),
      shrinks_standalone_images_to_fit(std::move(shrinks_standalone_images_to_fit_in)),
      text_areas_are_resizable(std::move(text_areas_are_resizable_in)),
      allow_scripts_to_close_windows(std::move(allow_scripts_to_close_windows_in)),
      remote_fonts_enabled(std::move(remote_fonts_enabled_in)),
      javascript_can_access_clipboard(std::move(javascript_can_access_clipboard_in)),
      xslt_enabled(std::move(xslt_enabled_in)),
      dns_prefetching_enabled(std::move(dns_prefetching_enabled_in)),
      data_saver_enabled(std::move(data_saver_enabled_in)),
      data_saver_holdback_web_api_enabled(std::move(data_saver_holdback_web_api_enabled_in)),
      local_storage_enabled(std::move(local_storage_enabled_in)),
      databases_enabled(std::move(databases_enabled_in)),
      application_cache_enabled(std::move(application_cache_enabled_in)),
      tabs_to_links(std::move(tabs_to_links_in)),
      disable_ipc_flooding_protection(std::move(disable_ipc_flooding_protection_in)),
      hyperlink_auditing_enabled(std::move(hyperlink_auditing_enabled_in)),
      allow_universal_access_from_file_urls(std::move(allow_universal_access_from_file_urls_in)),
      allow_file_access_from_file_urls(std::move(allow_file_access_from_file_urls_in)),
      webgl1_enabled(std::move(webgl1_enabled_in)),
      webgl2_enabled(std::move(webgl2_enabled_in)),
      pepper_3d_enabled(std::move(pepper_3d_enabled_in)),
      flash_3d_enabled(std::move(flash_3d_enabled_in)),
      flash_stage3d_enabled(std::move(flash_stage3d_enabled_in)),
      flash_stage3d_baseline_enabled(std::move(flash_stage3d_baseline_enabled_in)),
      privileged_webgl_extensions_enabled(std::move(privileged_webgl_extensions_enabled_in)),
      webgl_errors_to_console_enabled(std::move(webgl_errors_to_console_enabled_in)),
      hide_scrollbars(std::move(hide_scrollbars_in)),
      accelerated_2d_canvas_enabled(std::move(accelerated_2d_canvas_enabled_in)),
      new_canvas_2d_api_enabled(std::move(new_canvas_2d_api_enabled_in)),
      antialiased_2d_canvas_disabled(std::move(antialiased_2d_canvas_disabled_in)),
      antialiased_clips_2d_canvas_enabled(std::move(antialiased_clips_2d_canvas_enabled_in)),
      accelerated_filters_enabled(std::move(accelerated_filters_enabled_in)),
      deferred_filters_enabled(std::move(deferred_filters_enabled_in)),
      container_culling_enabled(std::move(container_culling_enabled_in)),
      allow_running_insecure_content(std::move(allow_running_insecure_content_in)),
      disable_reading_from_canvas(std::move(disable_reading_from_canvas_in)),
      strict_mixed_content_checking(std::move(strict_mixed_content_checking_in)),
      strict_powerful_feature_restrictions(std::move(strict_powerful_feature_restrictions_in)),
      allow_geolocation_on_insecure_origins(std::move(allow_geolocation_on_insecure_origins_in)),
      strictly_block_blockable_mixed_content(std::move(strictly_block_blockable_mixed_content_in)),
      block_mixed_plugin_content(std::move(block_mixed_plugin_content_in)),
      password_echo_enabled(std::move(password_echo_enabled_in)),
      should_clear_document_background(std::move(should_clear_document_background_in)),
      enable_scroll_animator(std::move(enable_scroll_animator_in)),
      prefers_reduced_motion(std::move(prefers_reduced_motion_in)),
      touch_event_feature_detection_enabled(std::move(touch_event_feature_detection_enabled_in)),
      enable_error_page(std::move(enable_error_page_in)),
      pointer_events_max_touch_points(std::move(pointer_events_max_touch_points_in)),
      available_pointer_types(std::move(available_pointer_types_in)),
      primary_pointer_type(std::move(primary_pointer_type_in)),
      available_hover_types(std::move(available_hover_types_in)),
      primary_hover_type(std::move(primary_hover_type_in)),
      dont_send_key_events_to_javascript(std::move(dont_send_key_events_to_javascript_in)),
      barrel_button_for_drag_enabled(std::move(barrel_button_for_drag_enabled_in)),
      sync_xhr_in_documents_enabled(std::move(sync_xhr_in_documents_enabled_in)),
      number_of_cpu_cores(std::move(number_of_cpu_cores_in)),
      editing_behavior(std::move(editing_behavior_in)),
      supports_multiple_windows(std::move(supports_multiple_windows_in)),
      viewport_enabled(std::move(viewport_enabled_in)),
      viewport_meta_enabled(std::move(viewport_meta_enabled_in)),
      shrinks_viewport_contents_to_fit(std::move(shrinks_viewport_contents_to_fit_in)),
      viewport_style(std::move(viewport_style_in)),
      smooth_scroll_for_find_enabled(std::move(smooth_scroll_for_find_enabled_in)),
      main_frame_resizes_are_orientation_changes(std::move(main_frame_resizes_are_orientation_changes_in)),
      initialize_at_minimum_page_scale(std::move(initialize_at_minimum_page_scale_in)),
      smart_insert_delete_enabled(std::move(smart_insert_delete_enabled_in)),
      spatial_navigation_enabled(std::move(spatial_navigation_enabled_in)),
      navigate_on_drag_drop(std::move(navigate_on_drag_drop_in)),
      v8_cache_options(std::move(v8_cache_options_in)),
      record_whole_document(std::move(record_whole_document_in)),
      cookie_enabled(std::move(cookie_enabled_in)),
      accelerated_video_decode_enabled(std::move(accelerated_video_decode_enabled_in)),
      animation_policy(std::move(animation_policy_in)),
      user_gesture_required_for_presentation(std::move(user_gesture_required_for_presentation_in)),
      text_tracks_enabled(std::move(text_tracks_enabled_in)),
      text_track_background_color(std::move(text_track_background_color_in)),
      text_track_text_color(std::move(text_track_text_color_in)),
      text_track_text_size(std::move(text_track_text_size_in)),
      text_track_text_shadow(std::move(text_track_text_shadow_in)),
      text_track_font_family(std::move(text_track_font_family_in)),
      text_track_font_style(std::move(text_track_font_style_in)),
      text_track_font_variant(std::move(text_track_font_variant_in)),
      text_track_window_color(std::move(text_track_window_color_in)),
      text_track_window_padding(std::move(text_track_window_padding_in)),
      text_track_window_radius(std::move(text_track_window_radius_in)),
      text_track_margin_percentage(std::move(text_track_margin_percentage_in)),
      immersive_mode_enabled(std::move(immersive_mode_enabled_in)),
      double_tap_to_zoom_enabled(std::move(double_tap_to_zoom_enabled_in)),
      fullscreen_supported(std::move(fullscreen_supported_in)),
      text_autosizing_enabled(std::move(text_autosizing_enabled_in)),
      web_app_scope(std::move(web_app_scope_in)),
      force_dark_mode_enabled(std::move(force_dark_mode_enabled_in)),
      default_minimum_page_scale_factor(std::move(default_minimum_page_scale_factor_in)),
      default_maximum_page_scale_factor(std::move(default_maximum_page_scale_factor_in)),
      hide_download_ui(std::move(hide_download_ui_in)),
      presentation_receiver(std::move(presentation_receiver_in)),
      media_controls_enabled(std::move(media_controls_enabled_in)),
      do_not_update_selection_on_mutating_selection_range(std::move(do_not_update_selection_on_mutating_selection_range_in)),
      autoplay_policy(std::move(autoplay_policy_in)),
      preferred_color_scheme(std::move(preferred_color_scheme_in)),
      low_priority_iframes_threshold(std::move(low_priority_iframes_threshold_in)),
      picture_in_picture_enabled(std::move(picture_in_picture_enabled_in)),
      translate_service_available(std::move(translate_service_available_in)),
      network_quality_estimator_web_holdback(std::move(network_quality_estimator_web_holdback_in)),
      lazy_load_enabled(std::move(lazy_load_enabled_in)),
      lazy_frame_loading_distance_thresholds_px(std::move(lazy_frame_loading_distance_thresholds_px_in)),
      lazy_image_loading_distance_thresholds_px(std::move(lazy_image_loading_distance_thresholds_px_in)),
      lazy_image_first_k_fully_load(std::move(lazy_image_first_k_fully_load_in)),
      allow_mixed_content_upgrades(std::move(allow_mixed_content_upgrades_in)),
      always_show_focus(std::move(always_show_focus_in)),
      touch_drag_drop_enabled(std::move(touch_drag_drop_enabled_in)) {}

WebPreferences::~WebPreferences() = default;

void WebPreferences::AsValueInto(base::trace_event::TracedValue* value) const {
  value->BeginDictionary("standard_font_family_map");
  for (const auto& item0 : this->standard_font_family_map) {
    value->SetStringWithCopiedName(base::trace_event::ValueToString(item0.first, "<value of type const std::string&>"), base::trace_event::ValueToString(item0.second, "<value of type const ::base::string16&>"));
  }
  value->EndDictionary();
  value->BeginDictionary("fixed_font_family_map");
  for (const auto& item0 : this->fixed_font_family_map) {
    value->SetStringWithCopiedName(base::trace_event::ValueToString(item0.first, "<value of type const std::string&>"), base::trace_event::ValueToString(item0.second, "<value of type const ::base::string16&>"));
  }
  value->EndDictionary();
  value->BeginDictionary("serif_font_family_map");
  for (const auto& item0 : this->serif_font_family_map) {
    value->SetStringWithCopiedName(base::trace_event::ValueToString(item0.first, "<value of type const std::string&>"), base::trace_event::ValueToString(item0.second, "<value of type const ::base::string16&>"));
  }
  value->EndDictionary();
  value->BeginDictionary("sans_serif_font_family_map");
  for (const auto& item0 : this->sans_serif_font_family_map) {
    value->SetStringWithCopiedName(base::trace_event::ValueToString(item0.first, "<value of type const std::string&>"), base::trace_event::ValueToString(item0.second, "<value of type const ::base::string16&>"));
  }
  value->EndDictionary();
  value->BeginDictionary("cursive_font_family_map");
  for (const auto& item0 : this->cursive_font_family_map) {
    value->SetStringWithCopiedName(base::trace_event::ValueToString(item0.first, "<value of type const std::string&>"), base::trace_event::ValueToString(item0.second, "<value of type const ::base::string16&>"));
  }
  value->EndDictionary();
  value->BeginDictionary("fantasy_font_family_map");
  for (const auto& item0 : this->fantasy_font_family_map) {
    value->SetStringWithCopiedName(base::trace_event::ValueToString(item0.first, "<value of type const std::string&>"), base::trace_event::ValueToString(item0.second, "<value of type const ::base::string16&>"));
  }
  value->EndDictionary();
  value->BeginDictionary("pictograph_font_family_map");
  for (const auto& item0 : this->pictograph_font_family_map) {
    value->SetStringWithCopiedName(base::trace_event::ValueToString(item0.first, "<value of type const std::string&>"), base::trace_event::ValueToString(item0.second, "<value of type const ::base::string16&>"));
  }
  value->EndDictionary();
  value->SetInteger("default_font_size", this->default_font_size);
  value->SetInteger("default_fixed_font_size", this->default_fixed_font_size);
  value->SetInteger("minimum_font_size", this->minimum_font_size);
  value->SetInteger("minimum_logical_font_size", this->minimum_logical_font_size);
  value->SetString("default_encoding", this->default_encoding);
  value->SetBoolean("context_menu_on_mouse_up", this->context_menu_on_mouse_up);
  value->SetBoolean("javascript_enabled", this->javascript_enabled);
  value->SetBoolean("web_security_enabled", this->web_security_enabled);
  value->SetBoolean("loads_images_automatically", this->loads_images_automatically);
  value->SetBoolean("images_enabled", this->images_enabled);
  value->SetBoolean("plugins_enabled", this->plugins_enabled);
  value->SetBoolean("dom_paste_enabled", this->dom_paste_enabled);
  value->SetBoolean("shrinks_standalone_images_to_fit", this->shrinks_standalone_images_to_fit);
  value->SetBoolean("text_areas_are_resizable", this->text_areas_are_resizable);
  value->SetBoolean("allow_scripts_to_close_windows", this->allow_scripts_to_close_windows);
  value->SetBoolean("remote_fonts_enabled", this->remote_fonts_enabled);
  value->SetBoolean("javascript_can_access_clipboard", this->javascript_can_access_clipboard);
  value->SetBoolean("xslt_enabled", this->xslt_enabled);
  value->SetBoolean("dns_prefetching_enabled", this->dns_prefetching_enabled);
  value->SetBoolean("data_saver_enabled", this->data_saver_enabled);
  value->SetBoolean("data_saver_holdback_web_api_enabled", this->data_saver_holdback_web_api_enabled);
  value->SetBoolean("local_storage_enabled", this->local_storage_enabled);
  value->SetBoolean("databases_enabled", this->databases_enabled);
  value->SetBoolean("application_cache_enabled", this->application_cache_enabled);
  value->SetBoolean("tabs_to_links", this->tabs_to_links);
  value->SetBoolean("disable_ipc_flooding_protection", this->disable_ipc_flooding_protection);
  value->SetBoolean("hyperlink_auditing_enabled", this->hyperlink_auditing_enabled);
  value->SetBoolean("allow_universal_access_from_file_urls", this->allow_universal_access_from_file_urls);
  value->SetBoolean("allow_file_access_from_file_urls", this->allow_file_access_from_file_urls);
  value->SetBoolean("webgl1_enabled", this->webgl1_enabled);
  value->SetBoolean("webgl2_enabled", this->webgl2_enabled);
  value->SetBoolean("pepper_3d_enabled", this->pepper_3d_enabled);
  value->SetBoolean("flash_3d_enabled", this->flash_3d_enabled);
  value->SetBoolean("flash_stage3d_enabled", this->flash_stage3d_enabled);
  value->SetBoolean("flash_stage3d_baseline_enabled", this->flash_stage3d_baseline_enabled);
  value->SetBoolean("privileged_webgl_extensions_enabled", this->privileged_webgl_extensions_enabled);
  value->SetBoolean("webgl_errors_to_console_enabled", this->webgl_errors_to_console_enabled);
  value->SetBoolean("hide_scrollbars", this->hide_scrollbars);
  value->SetBoolean("accelerated_2d_canvas_enabled", this->accelerated_2d_canvas_enabled);
  value->SetBoolean("new_canvas_2d_api_enabled", this->new_canvas_2d_api_enabled);
  value->SetBoolean("antialiased_2d_canvas_disabled", this->antialiased_2d_canvas_disabled);
  value->SetBoolean("antialiased_clips_2d_canvas_enabled", this->antialiased_clips_2d_canvas_enabled);
  value->SetBoolean("accelerated_filters_enabled", this->accelerated_filters_enabled);
  value->SetBoolean("deferred_filters_enabled", this->deferred_filters_enabled);
  value->SetBoolean("container_culling_enabled", this->container_culling_enabled);
  value->SetBoolean("allow_running_insecure_content", this->allow_running_insecure_content);
  value->SetBoolean("disable_reading_from_canvas", this->disable_reading_from_canvas);
  value->SetBoolean("strict_mixed_content_checking", this->strict_mixed_content_checking);
  value->SetBoolean("strict_powerful_feature_restrictions", this->strict_powerful_feature_restrictions);
  value->SetBoolean("allow_geolocation_on_insecure_origins", this->allow_geolocation_on_insecure_origins);
  value->SetBoolean("strictly_block_blockable_mixed_content", this->strictly_block_blockable_mixed_content);
  value->SetBoolean("block_mixed_plugin_content", this->block_mixed_plugin_content);
  value->SetBoolean("password_echo_enabled", this->password_echo_enabled);
  value->SetBoolean("should_clear_document_background", this->should_clear_document_background);
  value->SetBoolean("enable_scroll_animator", this->enable_scroll_animator);
  value->SetBoolean("prefers_reduced_motion", this->prefers_reduced_motion);
  value->SetBoolean("touch_event_feature_detection_enabled", this->touch_event_feature_detection_enabled);
  value->SetBoolean("enable_error_page", this->enable_error_page);
  value->SetInteger("pointer_events_max_touch_points", this->pointer_events_max_touch_points);
  value->SetInteger("available_pointer_types", this->available_pointer_types);
  value->SetString("primary_pointer_type", base::trace_event::ValueToString(this->primary_pointer_type));
  value->SetInteger("available_hover_types", this->available_hover_types);
  value->SetString("primary_hover_type", base::trace_event::ValueToString(this->primary_hover_type));
  value->SetBoolean("dont_send_key_events_to_javascript", this->dont_send_key_events_to_javascript);
  value->SetBoolean("barrel_button_for_drag_enabled", this->barrel_button_for_drag_enabled);
  value->SetBoolean("sync_xhr_in_documents_enabled", this->sync_xhr_in_documents_enabled);
  value->SetInteger("number_of_cpu_cores", this->number_of_cpu_cores);
  value->SetString("editing_behavior", base::trace_event::ValueToString(this->editing_behavior));
  value->SetBoolean("supports_multiple_windows", this->supports_multiple_windows);
  value->SetBoolean("viewport_enabled", this->viewport_enabled);
  value->SetBoolean("viewport_meta_enabled", this->viewport_meta_enabled);
  value->SetBoolean("shrinks_viewport_contents_to_fit", this->shrinks_viewport_contents_to_fit);
  value->SetString("viewport_style", base::trace_event::ValueToString(this->viewport_style));
  value->SetBoolean("smooth_scroll_for_find_enabled", this->smooth_scroll_for_find_enabled);
  value->SetBoolean("main_frame_resizes_are_orientation_changes", this->main_frame_resizes_are_orientation_changes);
  value->SetBoolean("initialize_at_minimum_page_scale", this->initialize_at_minimum_page_scale);
  value->SetBoolean("smart_insert_delete_enabled", this->smart_insert_delete_enabled);
  value->SetBoolean("spatial_navigation_enabled", this->spatial_navigation_enabled);
  value->SetBoolean("navigate_on_drag_drop", this->navigate_on_drag_drop);
  value->SetString("v8_cache_options", base::trace_event::ValueToString(this->v8_cache_options));
  value->SetBoolean("record_whole_document", this->record_whole_document);
  value->SetBoolean("cookie_enabled", this->cookie_enabled);
  value->SetBoolean("accelerated_video_decode_enabled", this->accelerated_video_decode_enabled);
  value->SetString("animation_policy", base::trace_event::ValueToString(this->animation_policy));
  value->SetBoolean("user_gesture_required_for_presentation", this->user_gesture_required_for_presentation);
  value->SetBoolean("text_tracks_enabled", this->text_tracks_enabled);
  value->SetString("text_track_background_color", this->text_track_background_color);
  value->SetString("text_track_text_color", this->text_track_text_color);
  value->SetString("text_track_text_size", this->text_track_text_size);
  value->SetString("text_track_text_shadow", this->text_track_text_shadow);
  value->SetString("text_track_font_family", this->text_track_font_family);
  value->SetString("text_track_font_style", this->text_track_font_style);
  value->SetString("text_track_font_variant", this->text_track_font_variant);
  value->SetString("text_track_window_color", this->text_track_window_color);
  value->SetString("text_track_window_padding", this->text_track_window_padding);
  value->SetString("text_track_window_radius", this->text_track_window_radius);
  value->SetDouble("text_track_margin_percentage", this->text_track_margin_percentage);
  value->SetBoolean("immersive_mode_enabled", this->immersive_mode_enabled);
  value->SetBoolean("double_tap_to_zoom_enabled", this->double_tap_to_zoom_enabled);
  value->SetBoolean("fullscreen_supported", this->fullscreen_supported);
  value->SetBoolean("text_autosizing_enabled", this->text_autosizing_enabled);
  value->SetString("web_app_scope", base::trace_event::ValueToString(this->web_app_scope, "<value of type const ::GURL&>"));
  value->SetBoolean("force_dark_mode_enabled", this->force_dark_mode_enabled);
  value->SetDouble("default_minimum_page_scale_factor", this->default_minimum_page_scale_factor);
  value->SetDouble("default_maximum_page_scale_factor", this->default_maximum_page_scale_factor);
  value->SetBoolean("hide_download_ui", this->hide_download_ui);
  value->SetBoolean("presentation_receiver", this->presentation_receiver);
  value->SetBoolean("media_controls_enabled", this->media_controls_enabled);
  value->SetBoolean("do_not_update_selection_on_mutating_selection_range", this->do_not_update_selection_on_mutating_selection_range);
  value->SetString("autoplay_policy", base::trace_event::ValueToString(this->autoplay_policy));
  value->SetString("preferred_color_scheme", base::trace_event::ValueToString(this->preferred_color_scheme));
  value->SetString("low_priority_iframes_threshold", base::trace_event::ValueToString(this->low_priority_iframes_threshold));
  value->SetBoolean("picture_in_picture_enabled", this->picture_in_picture_enabled);
  value->SetBoolean("translate_service_available", this->translate_service_available);
  value->SetString("network_quality_estimator_web_holdback", base::trace_event::ValueToString(this->network_quality_estimator_web_holdback));
  value->SetBoolean("lazy_load_enabled", this->lazy_load_enabled);
  value->BeginDictionary("lazy_frame_loading_distance_thresholds_px");
  for (const auto& item0 : this->lazy_frame_loading_distance_thresholds_px) {
    value->SetIntegerWithCopiedName(base::trace_event::ValueToString(item0.first, "<value of type EffectiveConnectionType>"), item0.second);
  }
  value->EndDictionary();
  value->BeginDictionary("lazy_image_loading_distance_thresholds_px");
  for (const auto& item0 : this->lazy_image_loading_distance_thresholds_px) {
    value->SetIntegerWithCopiedName(base::trace_event::ValueToString(item0.first, "<value of type EffectiveConnectionType>"), item0.second);
  }
  value->EndDictionary();
  value->BeginDictionary("lazy_image_first_k_fully_load");
  for (const auto& item0 : this->lazy_image_first_k_fully_load) {
    value->SetIntegerWithCopiedName(base::trace_event::ValueToString(item0.first, "<value of type EffectiveConnectionType>"), item0.second);
  }
  value->EndDictionary();
  value->SetBoolean("allow_mixed_content_upgrades", this->allow_mixed_content_upgrades);
  value->SetBoolean("always_show_focus", this->always_show_focus);
  value->SetBoolean("touch_drag_drop_enabled", this->touch_drag_drop_enabled);
}

bool WebPreferences::Validate(
    const void* data,
    mojo::internal::ValidationContext* validation_context) {
  return Data_::Validate(data, validation_context);
}
}  // namespace mojom
}  // namespace blink

namespace mojo {


// static
bool StructTraits<::blink::mojom::WebPreferences::DataView, ::blink::mojom::WebPreferencesPtr>::Read(
    ::blink::mojom::WebPreferences::DataView input,
    ::blink::mojom::WebPreferencesPtr* output) {
  bool success = true;
  ::blink::mojom::WebPreferencesPtr result(::blink::mojom::WebPreferences::New());
  
      if (success && !input.ReadStandardFontFamilyMap(&result->standard_font_family_map))
        success = false;
      if (success && !input.ReadFixedFontFamilyMap(&result->fixed_font_family_map))
        success = false;
      if (success && !input.ReadSerifFontFamilyMap(&result->serif_font_family_map))
        success = false;
      if (success && !input.ReadSansSerifFontFamilyMap(&result->sans_serif_font_family_map))
        success = false;
      if (success && !input.ReadCursiveFontFamilyMap(&result->cursive_font_family_map))
        success = false;
      if (success && !input.ReadFantasyFontFamilyMap(&result->fantasy_font_family_map))
        success = false;
      if (success && !input.ReadPictographFontFamilyMap(&result->pictograph_font_family_map))
        success = false;
      if (success)
        result->default_font_size = input.default_font_size();
      if (success)
        result->default_fixed_font_size = input.default_fixed_font_size();
      if (success)
        result->minimum_font_size = input.minimum_font_size();
      if (success)
        result->minimum_logical_font_size = input.minimum_logical_font_size();
      if (success && !input.ReadDefaultEncoding(&result->default_encoding))
        success = false;
      if (success)
        result->context_menu_on_mouse_up = input.context_menu_on_mouse_up();
      if (success)
        result->javascript_enabled = input.javascript_enabled();
      if (success)
        result->web_security_enabled = input.web_security_enabled();
      if (success)
        result->loads_images_automatically = input.loads_images_automatically();
      if (success)
        result->images_enabled = input.images_enabled();
      if (success)
        result->plugins_enabled = input.plugins_enabled();
      if (success)
        result->dom_paste_enabled = input.dom_paste_enabled();
      if (success)
        result->shrinks_standalone_images_to_fit = input.shrinks_standalone_images_to_fit();
      if (success)
        result->text_areas_are_resizable = input.text_areas_are_resizable();
      if (success)
        result->allow_scripts_to_close_windows = input.allow_scripts_to_close_windows();
      if (success)
        result->remote_fonts_enabled = input.remote_fonts_enabled();
      if (success)
        result->javascript_can_access_clipboard = input.javascript_can_access_clipboard();
      if (success)
        result->xslt_enabled = input.xslt_enabled();
      if (success)
        result->dns_prefetching_enabled = input.dns_prefetching_enabled();
      if (success)
        result->data_saver_enabled = input.data_saver_enabled();
      if (success)
        result->data_saver_holdback_web_api_enabled = input.data_saver_holdback_web_api_enabled();
      if (success)
        result->local_storage_enabled = input.local_storage_enabled();
      if (success)
        result->databases_enabled = input.databases_enabled();
      if (success)
        result->application_cache_enabled = input.application_cache_enabled();
      if (success)
        result->tabs_to_links = input.tabs_to_links();
      if (success)
        result->disable_ipc_flooding_protection = input.disable_ipc_flooding_protection();
      if (success)
        result->hyperlink_auditing_enabled = input.hyperlink_auditing_enabled();
      if (success)
        result->allow_universal_access_from_file_urls = input.allow_universal_access_from_file_urls();
      if (success)
        result->allow_file_access_from_file_urls = input.allow_file_access_from_file_urls();
      if (success)
        result->webgl1_enabled = input.webgl1_enabled();
      if (success)
        result->webgl2_enabled = input.webgl2_enabled();
      if (success)
        result->pepper_3d_enabled = input.pepper_3d_enabled();
      if (success)
        result->flash_3d_enabled = input.flash_3d_enabled();
      if (success)
        result->flash_stage3d_enabled = input.flash_stage3d_enabled();
      if (success)
        result->flash_stage3d_baseline_enabled = input.flash_stage3d_baseline_enabled();
      if (success)
        result->privileged_webgl_extensions_enabled = input.privileged_webgl_extensions_enabled();
      if (success)
        result->webgl_errors_to_console_enabled = input.webgl_errors_to_console_enabled();
      if (success)
        result->hide_scrollbars = input.hide_scrollbars();
      if (success)
        result->accelerated_2d_canvas_enabled = input.accelerated_2d_canvas_enabled();
      if (success)
        result->new_canvas_2d_api_enabled = input.new_canvas_2d_api_enabled();
      if (success)
        result->antialiased_2d_canvas_disabled = input.antialiased_2d_canvas_disabled();
      if (success)
        result->antialiased_clips_2d_canvas_enabled = input.antialiased_clips_2d_canvas_enabled();
      if (success)
        result->accelerated_filters_enabled = input.accelerated_filters_enabled();
      if (success)
        result->deferred_filters_enabled = input.deferred_filters_enabled();
      if (success)
        result->container_culling_enabled = input.container_culling_enabled();
      if (success)
        result->allow_running_insecure_content = input.allow_running_insecure_content();
      if (success)
        result->disable_reading_from_canvas = input.disable_reading_from_canvas();
      if (success)
        result->strict_mixed_content_checking = input.strict_mixed_content_checking();
      if (success)
        result->strict_powerful_feature_restrictions = input.strict_powerful_feature_restrictions();
      if (success)
        result->allow_geolocation_on_insecure_origins = input.allow_geolocation_on_insecure_origins();
      if (success)
        result->strictly_block_blockable_mixed_content = input.strictly_block_blockable_mixed_content();
      if (success)
        result->block_mixed_plugin_content = input.block_mixed_plugin_content();
      if (success)
        result->password_echo_enabled = input.password_echo_enabled();
      if (success)
        result->should_clear_document_background = input.should_clear_document_background();
      if (success)
        result->enable_scroll_animator = input.enable_scroll_animator();
      if (success)
        result->prefers_reduced_motion = input.prefers_reduced_motion();
      if (success)
        result->touch_event_feature_detection_enabled = input.touch_event_feature_detection_enabled();
      if (success)
        result->enable_error_page = input.enable_error_page();
      if (success)
        result->pointer_events_max_touch_points = input.pointer_events_max_touch_points();
      if (success)
        result->available_pointer_types = input.available_pointer_types();
      if (success && !input.ReadPrimaryPointerType(&result->primary_pointer_type))
        success = false;
      if (success)
        result->available_hover_types = input.available_hover_types();
      if (success && !input.ReadPrimaryHoverType(&result->primary_hover_type))
        success = false;
      if (success)
        result->dont_send_key_events_to_javascript = input.dont_send_key_events_to_javascript();
      if (success)
        result->barrel_button_for_drag_enabled = input.barrel_button_for_drag_enabled();
      if (success)
        result->sync_xhr_in_documents_enabled = input.sync_xhr_in_documents_enabled();
      if (success)
        result->number_of_cpu_cores = input.number_of_cpu_cores();
      if (success && !input.ReadEditingBehavior(&result->editing_behavior))
        success = false;
      if (success)
        result->supports_multiple_windows = input.supports_multiple_windows();
      if (success)
        result->viewport_enabled = input.viewport_enabled();
      if (success)
        result->viewport_meta_enabled = input.viewport_meta_enabled();
      if (success)
        result->shrinks_viewport_contents_to_fit = input.shrinks_viewport_contents_to_fit();
      if (success && !input.ReadViewportStyle(&result->viewport_style))
        success = false;
      if (success)
        result->smooth_scroll_for_find_enabled = input.smooth_scroll_for_find_enabled();
      if (success)
        result->main_frame_resizes_are_orientation_changes = input.main_frame_resizes_are_orientation_changes();
      if (success)
        result->initialize_at_minimum_page_scale = input.initialize_at_minimum_page_scale();
      if (success)
        result->smart_insert_delete_enabled = input.smart_insert_delete_enabled();
      if (success)
        result->spatial_navigation_enabled = input.spatial_navigation_enabled();
      if (success)
        result->navigate_on_drag_drop = input.navigate_on_drag_drop();
      if (success && !input.ReadV8CacheOptions(&result->v8_cache_options))
        success = false;
      if (success)
        result->record_whole_document = input.record_whole_document();
      if (success)
        result->cookie_enabled = input.cookie_enabled();
      if (success)
        result->accelerated_video_decode_enabled = input.accelerated_video_decode_enabled();
      if (success && !input.ReadAnimationPolicy(&result->animation_policy))
        success = false;
      if (success)
        result->user_gesture_required_for_presentation = input.user_gesture_required_for_presentation();
      if (success)
        result->text_tracks_enabled = input.text_tracks_enabled();
      if (success && !input.ReadTextTrackBackgroundColor(&result->text_track_background_color))
        success = false;
      if (success && !input.ReadTextTrackTextColor(&result->text_track_text_color))
        success = false;
      if (success && !input.ReadTextTrackTextSize(&result->text_track_text_size))
        success = false;
      if (success && !input.ReadTextTrackTextShadow(&result->text_track_text_shadow))
        success = false;
      if (success && !input.ReadTextTrackFontFamily(&result->text_track_font_family))
        success = false;
      if (success && !input.ReadTextTrackFontStyle(&result->text_track_font_style))
        success = false;
      if (success && !input.ReadTextTrackFontVariant(&result->text_track_font_variant))
        success = false;
      if (success && !input.ReadTextTrackWindowColor(&result->text_track_window_color))
        success = false;
      if (success && !input.ReadTextTrackWindowPadding(&result->text_track_window_padding))
        success = false;
      if (success && !input.ReadTextTrackWindowRadius(&result->text_track_window_radius))
        success = false;
      if (success)
        result->text_track_margin_percentage = input.text_track_margin_percentage();
      if (success)
        result->immersive_mode_enabled = input.immersive_mode_enabled();
      if (success)
        result->double_tap_to_zoom_enabled = input.double_tap_to_zoom_enabled();
      if (success)
        result->fullscreen_supported = input.fullscreen_supported();
      if (success)
        result->text_autosizing_enabled = input.text_autosizing_enabled();
      if (success && !input.ReadWebAppScope(&result->web_app_scope))
        success = false;
      if (success)
        result->force_dark_mode_enabled = input.force_dark_mode_enabled();
      if (success)
        result->default_minimum_page_scale_factor = input.default_minimum_page_scale_factor();
      if (success)
        result->default_maximum_page_scale_factor = input.default_maximum_page_scale_factor();
      if (success)
        result->hide_download_ui = input.hide_download_ui();
      if (success)
        result->presentation_receiver = input.presentation_receiver();
      if (success)
        result->media_controls_enabled = input.media_controls_enabled();
      if (success)
        result->do_not_update_selection_on_mutating_selection_range = input.do_not_update_selection_on_mutating_selection_range();
      if (success && !input.ReadAutoplayPolicy(&result->autoplay_policy))
        success = false;
      if (success && !input.ReadPreferredColorScheme(&result->preferred_color_scheme))
        success = false;
      if (success && !input.ReadLowPriorityIframesThreshold(&result->low_priority_iframes_threshold))
        success = false;
      if (success)
        result->picture_in_picture_enabled = input.picture_in_picture_enabled();
      if (success)
        result->translate_service_available = input.translate_service_available();
      if (success && !input.ReadNetworkQualityEstimatorWebHoldback(&result->network_quality_estimator_web_holdback))
        success = false;
      if (success)
        result->lazy_load_enabled = input.lazy_load_enabled();
      if (success && !input.ReadLazyFrameLoadingDistanceThresholdsPx(&result->lazy_frame_loading_distance_thresholds_px))
        success = false;
      if (success && !input.ReadLazyImageLoadingDistanceThresholdsPx(&result->lazy_image_loading_distance_thresholds_px))
        success = false;
      if (success && !input.ReadLazyImageFirstKFullyLoad(&result->lazy_image_first_k_fully_load))
        success = false;
      if (success)
        result->allow_mixed_content_upgrades = input.allow_mixed_content_upgrades();
      if (success)
        result->always_show_focus = input.always_show_focus();
      if (success)
        result->touch_drag_drop_enabled = input.touch_drag_drop_enabled();
  *output = std::move(result);
  return success;
}

}  // namespace mojo

#if defined(__clang__)
#pragma clang diagnostic pop
#endif