create static method

BackgroundFill create({
  1. bool schemeUtilsIsSetDefaultData = false,
  2. String special_type = "backgroundFill",
  3. bool special_is_json_scheme_class = true,
  4. String special_return_type = "backgroundFill",
  5. BackgroundFillSolid? background_fill_solid,
  6. BackgroundFillGradient? background_fill_gradient,
  7. BackgroundFillFreeformGradient? background_fill_freeform_gradient,
})
override

Generate By General Universe Script Dont edit by hand or anything manual

Implementation

static BackgroundFill create({
  bool schemeUtilsIsSetDefaultData = false,
  String special_type = "backgroundFill",
  bool special_is_json_scheme_class = true,
  String special_return_type = "backgroundFill",
  BackgroundFillSolid? background_fill_solid,
  BackgroundFillGradient? background_fill_gradient,
  BackgroundFillFreeformGradient? background_fill_freeform_gradient,
}) {
  // BackgroundFill backgroundFill = BackgroundFill({
  final Map backgroundFill_data_create_json = {
    "@type": special_type,
    "@is_json_scheme_class": special_is_json_scheme_class,
    "@return_type": special_return_type,
    "background_fill_solid": (background_fill_solid != null) ? background_fill_solid.toJson() : null,
    "background_fill_gradient": (background_fill_gradient != null) ? background_fill_gradient.toJson() : null,
    "background_fill_freeform_gradient": (background_fill_freeform_gradient != null) ? background_fill_freeform_gradient.toJson() : null,
  };

  backgroundFill_data_create_json.removeWhere((key, value) => value == null);

  if (schemeUtilsIsSetDefaultData) {
    defaultData.forEach((key, value) {
      if (backgroundFill_data_create_json.containsKey(key) == false) {
        backgroundFill_data_create_json[key] = value;
      }
    });
  }
  return BackgroundFill(backgroundFill_data_create_json);
}