toMap method

Map<String, dynamic> toMap()

Implementation

Map<String, dynamic> toMap() {
  return {
    'id': id,
    'gameId': gameId,
    'modId': modId,
    'isAvailable': isAvailable,
    'displayName': displayName,
    'fileName': fileName,
    'releaseType': releaseType.value,
    'fileStatus': fileStatus,
    'hashes': hashes.map((x) => x.toMap()).toList(),
    'fileDate': fileDate,
    'fileLength': fileLength,
    'downloadCount': downloadCount,
    'downloadUrl': downloadUrl,
    'gameVersions': gameVersions,
    'sortableGameVersions':
        sortableGameVersions.map((x) => x.toMap()).toList(),
    'dependencies': dependencies,
    'alternateFileId': alternateFileId,
    'isServerPack': isServerPack,
    'fileFingerprint': fileFingerprint,
    'modules': modules.map((x) => x.toMap()).toList(),
  };
}