Map<String, dynamic> get map => { if (path.isNotEmpty) 'path': path, if (!(id.isNaN)) 'id': id, if (name.isNotEmpty) 'name': name };