/* package */ static Map getBubblingEventTypeConstants() {
   return MapBuilder.builder()
       .put(
           "topChange",
           MapBuilder.of(
               "phasedRegistrationNames",
               MapBuilder.of("bubbled", "onChange", "captured", "onChangeCapture")))
       .put(
           "topSelect",
           MapBuilder.of(
               "phasedRegistrationNames",
               MapBuilder.of("bubbled", "onSelect", "captured", "onSelectCapture")))
       .put(
           TouchEventType.START.getJSEventName(),
           MapBuilder.of(
               "phasedRegistrationNames",
               MapBuilder.of("bubbled", "onTouchStart", "captured", "onTouchStartCapture")))
       .put(
           TouchEventType.MOVE.getJSEventName(),
           MapBuilder.of(
               "phasedRegistrationNames",
               MapBuilder.of("bubbled", "onTouchMove", "captured", "onTouchMoveCapture")))
       .put(
           TouchEventType.END.getJSEventName(),
           MapBuilder.of(
               "phasedRegistrationNames",
               MapBuilder.of("bubbled", "onTouchEnd", "captured", "onTouchEndCapture")))
       .build();
 }
 @Nullable
 @Override
 public Map<String, Object> getExportedViewConstants() {
   return MapBuilder.<String, Object>of(
       "SIZE",
       MapBuilder.of("DEFAULT", SwipeRefreshLayout.DEFAULT, "LARGE", SwipeRefreshLayout.LARGE));
 }
 @Nullable
 @Override
 public Map<String, Object> getExportedViewConstants() {
   return MapBuilder.<String, Object>of(
       "ShowAsAction",
       MapBuilder.of(
           "never", MenuItem.SHOW_AS_ACTION_NEVER,
           "always", MenuItem.SHOW_AS_ACTION_ALWAYS,
           "ifRoom", MenuItem.SHOW_AS_ACTION_IF_ROOM));
 }
 /* package */ static Map getDirectEventTypeConstants() {
   return MapBuilder.builder()
       .put("topContentSizeChange", MapBuilder.of("registrationName", "onContentSizeChange"))
       .put("topLayout", MapBuilder.of("registrationName", "onLayout"))
       .put("topLoadingError", MapBuilder.of("registrationName", "onLoadingError"))
       .put("topLoadingFinish", MapBuilder.of("registrationName", "onLoadingFinish"))
       .put("topLoadingStart", MapBuilder.of("registrationName", "onLoadingStart"))
       .put("topSelectionChange", MapBuilder.of("registrationName", "onSelectionChange"))
       .put("topMessage", MapBuilder.of("registrationName", "onMessage"))
       .build();
 }
 @Override
 public Map<String, Integer> getCommandsMap() {
   return MapBuilder.of("hotspotUpdate", CMD_HOTSPOT_UPDATE, "setPressed", CMD_SET_PRESSED);
 }
  public static Map<String, Object> getConstants() {
    HashMap<String, Object> constants = new HashMap<String, Object>();
    constants.put(
        "UIView",
        MapBuilder.of(
            "ContentMode",
            MapBuilder.of(
                "ScaleAspectFit",
                ImageView.ScaleType.FIT_CENTER.ordinal(),
                "ScaleAspectFill",
                ImageView.ScaleType.CENTER_CROP.ordinal(),
                "ScaleAspectCenter",
                ImageView.ScaleType.CENTER_INSIDE.ordinal())));

    DisplayMetrics displayMetrics = DisplayMetricsHolder.getWindowDisplayMetrics();
    DisplayMetrics screenDisplayMetrics = DisplayMetricsHolder.getScreenDisplayMetrics();
    constants.put(
        "Dimensions",
        MapBuilder.of(
            "windowPhysicalPixels",
            MapBuilder.of(
                "width",
                displayMetrics.widthPixels,
                "height",
                displayMetrics.heightPixels,
                "scale",
                displayMetrics.density,
                "fontScale",
                displayMetrics.scaledDensity,
                "densityDpi",
                displayMetrics.densityDpi),
            "screenPhysicalPixels",
            MapBuilder.of(
                "width",
                screenDisplayMetrics.widthPixels,
                "height",
                screenDisplayMetrics.heightPixels,
                "scale",
                screenDisplayMetrics.density,
                "fontScale",
                screenDisplayMetrics.scaledDensity,
                "densityDpi",
                screenDisplayMetrics.densityDpi)));

    constants.put(
        "StyleConstants",
        MapBuilder.of(
            "PointerEventsValues",
            MapBuilder.of(
                "none",
                PointerEvents.NONE.ordinal(),
                "boxNone",
                PointerEvents.BOX_NONE.ordinal(),
                "boxOnly",
                PointerEvents.BOX_ONLY.ordinal(),
                "unspecified",
                PointerEvents.AUTO.ordinal())));

    constants.put(
        "PopupMenu",
        MapBuilder.of(
            ACTION_DISMISSED, ACTION_DISMISSED, ACTION_ITEM_SELECTED, ACTION_ITEM_SELECTED));

    constants.put(
        "AccessibilityEventTypes",
        MapBuilder.of(
            "typeWindowStateChanged",
            AccessibilityEvent.TYPE_WINDOW_STATE_CHANGED,
            "typeViewClicked",
            AccessibilityEvent.TYPE_VIEW_CLICKED));

    return constants;
  }
 @Override
 public Map<String, Object> getExportedCustomDirectEventTypeConstants() {
   return MapBuilder.of(
       TabSelectedEvent.EVENT_NAME, (Object) MapBuilder.of("registrationName", "onTabSelected"));
 }
 @Override
 public Map<String, Object> getExportedCustomDirectEventTypeConstants() {
   return MapBuilder.<String, Object>builder()
       .put("topRefresh", MapBuilder.of("registrationName", "onRefresh"))
       .build();
 }