RED-9255: implement file exchange

* add simplified text file to layoutparsing file export
* add validation for fileId/dossierId combinations
This commit is contained in:
Kilian Schuettler 2024-06-20 11:55:48 +02:00
parent 4b61a19a95
commit e382e4e833

View File

@ -0,0 +1,21 @@
package com.iqser.red.service.persistence.service.v1.api.shared.model;
import java.util.Optional;
import java.util.Set;
import io.swagger.v3.oas.annotations.media.Schema;
public record ReanalysisSettings(
@Schema(description = "Provide a list of dossierIds to filter for. If the list is empty, every dossier is selected for reanalysis.", defaultValue = "[]") Set<String> dossierIds,
@Schema(description = "Provide a list of fileIds to filter for. If the list is empty, every file is selected for reanalysis.", defaultValue = "[]") Set<String> fileIds,
@Schema(description = "If set to true, layout parsing and named entity recognition will be repeated.", defaultValue = "false") boolean repeatStructureAnalysis,
@Schema(description = "Use this to create a filter for files to reanalyse. Matches anything if set to null.", defaultValue = "{}") FileStatusFilter fileStatusFilter
) {
public FileStatusFilter fileStatusFilter() {
return Optional.ofNullable(fileStatusFilter)
.orElse(new FileStatusFilter());
}
}