create static method
ChatEvent
create({
- bool schemeUtilsIsSetDefaultData = false,
- String special_type = "chatEvent",
- String special_return_type = "chatEvent",
- num? id,
- num? date,
- MessageSender? member_id,
- ChatEventAction? action,
override
Generate By General Universe Script Dont edit by hand or anything manual
Implementation
static ChatEvent create({
bool schemeUtilsIsSetDefaultData = false,
String special_type = "chatEvent",
String special_return_type = "chatEvent",
num? id,
num? date,
MessageSender? member_id,
ChatEventAction? action,
}) {
// ChatEvent chatEvent = ChatEvent({
final Map chatEvent_data_create_json = {
"@type": special_type,
"@return_type": special_return_type,
"id": id,
"date": date,
"member_id": (member_id != null) ? member_id.toJson() : null,
"action": (action != null) ? action.toJson() : null,
};
chatEvent_data_create_json.removeWhere((key, value) => value == null);
if (schemeUtilsIsSetDefaultData) {
defaultData.forEach((key, value) {
if (chatEvent_data_create_json.containsKey(key) == false) {
chatEvent_data_create_json[key] = value;
}
});
}
return ChatEvent(chatEvent_data_create_json);
}