create static method
Game
create({
- bool schemeUtilsIsSetDefaultData = false,
- String special_type = "game",
- String special_return_type = "game",
- num? id,
- String? short_name,
- String? title,
- FormattedText? text,
- String? description,
- Photo? photo,
- Animation? animation,
override
Generate By AZKADEV | Azka Axelion Gibran Script Dont edit by hand or anything manual
Implementation
static Game create({
bool schemeUtilsIsSetDefaultData = false,
String special_type = "game",
String special_return_type = "game",
num? id,
String? short_name,
String? title,
FormattedText? text,
String? description,
Photo? photo,
Animation? animation,
}) {
// Game game = Game({
final Map game_data_create_json = {
"@type": special_type,
"@return_type": special_return_type,
"id": id,
"short_name": short_name,
"title": title,
"text": (text != null) ? text.toJson() : null,
"description": description,
"photo": (photo != null) ? photo.toJson() : null,
"animation": (animation != null) ? animation.toJson() : null,
};
game_data_create_json.removeWhere((key, value) => value == null);
if (schemeUtilsIsSetDefaultData) {
defaultData.forEach((key, value) {
if (game_data_create_json.containsKey(key) == false) {
game_data_create_json[key] = value;
}
});
}
return Game(game_data_create_json);
}