create static method

CaptchaWord create({
  1. bool schemeUtilsIsSetDefaultData = false,
  2. String special_type = "captchaWord",
  3. List<num>? answer,
  4. List<String>? words,
})
override

return original data json

Implementation

static CaptchaWord create({
  bool schemeUtilsIsSetDefaultData = false,
  String special_type = "captchaWord",
  List<num>? answer,
  List<String>? words,
}) {
  // CaptchaWord captchaWord = CaptchaWord({
  final Map captchaWord_data_create_json = {
    "@type": special_type,
    "answer": answer,
    "words": words,
  };

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

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