create static method
File
create({
- bool schemeUtilsIsSetDefaultData = false,
- String special_type = "file",
- String special_return_type = "file",
- num? id,
- num? size,
- num? expected_size,
- LocalFile? local,
- RemoteFile? remote,
override
Generate By General Universe Script Dont edit by hand or anything manual
Implementation
static File create({
bool schemeUtilsIsSetDefaultData = false,
String special_type = "file",
String special_return_type = "file",
num? id,
num? size,
num? expected_size,
LocalFile? local,
RemoteFile? remote,
}) {
// File file = File({
final Map file_data_create_json = {
"@type": special_type,
"@return_type": special_return_type,
"id": id,
"size": size,
"expected_size": expected_size,
"local": (local != null) ? local.toJson() : null,
"remote": (remote != null) ? remote.toJson() : null,
};
file_data_create_json.removeWhere((key, value) => value == null);
if (schemeUtilsIsSetDefaultData) {
defaultData.forEach((key, value) {
if (file_data_create_json.containsKey(key) == false) {
file_data_create_json[key] = value;
}
});
}
return File(file_data_create_json);
}