(file: File, session: Session)
| 328 | |
| 329 | |
| 330 | def build_compound_file_packet(file: File, session: Session): |
| 331 | child_files = file.get_child_files(session = session) |
| 332 | instance_list = Instance.list( |
| 333 | session = session, |
| 334 | file_id = file.id) |
| 335 | instance_dict_list = [] |
| 336 | for instance in instance_list: |
| 337 | instance_dict_list.append(build_instance(instance, file)) |
| 338 | result = { |
| 339 | 'file': file.serialize_base_file(), |
| 340 | 'instance_list': instance_dict_list |
| 341 | } |
| 342 | for child_file in child_files: |
| 343 | result[child_file.id] = build_packet(file = child_file, |
| 344 | session = session) |
| 345 | return result |
| 346 | |
| 347 | |
| 348 | def build_geopacket(file, session): |
no test coverage detected