create static method

InputSticker create({
  1. bool schemeUtilsIsSetDefaultData = false,
  2. String special_type = "inputSticker",
  3. String special_return_type = "inputSticker",
  4. InputFile? sticker,
  5. StickerFormat? format,
  6. String? emojis,
  7. MaskPosition? mask_position,
  8. List<String>? keywords,
})
override

Generate By AZKADEV | Azka Axelion Gibran Script Dont edit by hand or anything manual

Implementation

static InputSticker create({
  bool schemeUtilsIsSetDefaultData = false,
  String special_type = "inputSticker",
  String special_return_type = "inputSticker",
  InputFile? sticker,
  StickerFormat? format,
  String? emojis,
  MaskPosition? mask_position,
  List<String>? keywords,
}) {
  // InputSticker inputSticker = InputSticker({
  final Map inputSticker_data_create_json = {
    "@type": special_type,
    "@return_type": special_return_type,
    "sticker": (sticker != null) ? sticker.toJson() : null,
    "format": (format != null) ? format.toJson() : null,
    "emojis": emojis,
    "mask_position": (mask_position != null) ? mask_position.toJson() : null,
    "keywords": keywords,
  };

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

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