@Nullable
  public FlipperObject toFlipperObject(@Nullable ImageDecodeOptions options) {
    if (options == null) {
      return null;
    }
    FlipperObject.Builder optionsJson = new FlipperObject.Builder();
    optionsJson.put("minDecodeIntervalMs", options.minDecodeIntervalMs);
    optionsJson.put("decodePreviewFrame", options.decodePreviewFrame);
    optionsJson.put("useLastFrameForPreview", options.useLastFrameForPreview);
    optionsJson.put("decodeAllFrames", options.decodeAllFrames);
    optionsJson.put("forceStaticImage", options.forceStaticImage);
    optionsJson.put("bitmapConfig", options.bitmapConfig.name());
    optionsJson.put(
        "customImageDecoder",
        options.customImageDecoder == null ? "" : options.customImageDecoder.toString());
    return optionsJson.build();
  }
Serialization helper to create {@link FlipperObject}s.
tools/flipper-fresco-plugin/src/main/java/com/facebook/flipper/plugins/fresco/objecthelper/FlipperObjectHelper.java