fileName static method
Generates the file name from the file reference ID.
Implementation
static String fileName(String fileRefId) {
final parts = fileRefId.split('-');
assert(parts.length == 3, 'Invalid file reference: $fileRefId');
final [prefix, id, format] = parts;
assert(prefix.toLowerCase() == 'file',
'Invalid file reference: $fileRefId. Must begin with "file"');
return '$id.$format';
}