Search in sources :

Example 1 with FormMetadataPort

use of org.opendatakit.briefcase.model.form.FormMetadataPort in project briefcase by opendatakit.

the class ExportPanel method export.

private void export() {
    Stream<Job<?>> allJobs = forms.getSelectedForms().stream().map(form -> {
        FormKey key = FormKey.from(form);
        FormMetadata formMetadata = formMetadataPort.fetch(key).orElseThrow(BriefcaseException::new);
        form.setStatusString("Starting to export form");
        String formId = form.getFormDefinition().getFormId();
        ExportConfiguration configuration = forms.getConfiguration(formId);
        FormDefinition formDef = FormDefinition.from((BriefcaseFormDefinition) form.getFormDefinition());
        // TODO Abstract away the subtype of RemoteServer. This should say Optional<RemoteServer>
        Optional<AggregateServer> savedPullSource = RemoteServer.readFromPrefs(appPreferences, pullPanelPrefs, form);
        Job<Void> pullJob = configuration.resolvePullBefore() && savedPullSource.isPresent() ? new PullFromAggregate(http, savedPullSource.get(), appPreferences.getBriefcaseDir().orElseThrow(BriefcaseException::new), false, EventBus::publish, formMetadataPort).pull(form, appPreferences.resolveStartFromLast() ? Optional.of(formMetadata.getCursor()) : Optional.empty()) : Job.noOpSupplier();
        Job<Void> exportJob = Job.run(runnerStatus -> ExportToCsv.export(formMetadataPort, formMetadata, form, formDef, appPreferences.getBriefcaseDir().orElseThrow(BriefcaseException::new), configuration, analytics));
        Job<Void> exportGeoJsonJob = configuration.resolveIncludeGeoJsonExport() ? Job.run(runnerStatus -> ExportToGeoJson.export(formMetadata, formDef, configuration, analytics)) : Job.noOp;
        return Job.run(runnerStatus -> form.clearStatusHistory()).thenRun(pullJob).thenRun(exportJob).thenRun(exportGeoJsonJob);
    });
    JobsRunner.launchAsync(allJobs).onComplete(form::unsetExporting).waitForCompletion();
}
Also used : Builder.load(org.opendatakit.briefcase.export.ExportConfiguration.Builder.load) FormDefinition(org.opendatakit.briefcase.export.FormDefinition) LocalDateTime(java.time.LocalDateTime) BriefcasePreferences(org.opendatakit.briefcase.model.BriefcasePreferences) RemoteServer(org.opendatakit.briefcase.reused.transfer.RemoteServer) BriefcaseFormDefinition(org.opendatakit.briefcase.model.BriefcaseFormDefinition) ArrayList(java.util.ArrayList) ExportToGeoJson(org.opendatakit.briefcase.export.ExportToGeoJson) Builder.empty(org.opendatakit.briefcase.export.ExportConfiguration.Builder.empty) AnnotationProcessor(org.bushe.swing.event.annotation.AnnotationProcessor) FormMetadataPort(org.opendatakit.briefcase.model.form.FormMetadataPort) EventBus(org.bushe.swing.event.EventBus) ExportConfiguration(org.opendatakit.briefcase.export.ExportConfiguration) ISO_DATE_TIME(java.time.format.DateTimeFormatter.ISO_DATE_TIME) FormMetadata(org.opendatakit.briefcase.model.form.FormMetadata) BriefcaseException(org.opendatakit.briefcase.reused.BriefcaseException) AggregateServer(org.opendatakit.briefcase.reused.transfer.AggregateServer) ExportForms(org.opendatakit.briefcase.export.ExportForms) FormCache(org.opendatakit.briefcase.util.FormCache) FormKey(org.opendatakit.briefcase.model.form.FormKey) ExportForms.buildCustomConfPrefix(org.opendatakit.briefcase.export.ExportForms.buildCustomConfPrefix) FormStatus(org.opendatakit.briefcase.model.FormStatus) JobsRunner(org.opendatakit.briefcase.reused.job.JobsRunner) UI.errorMessage(org.opendatakit.briefcase.ui.reused.UI.errorMessage) Http(org.opendatakit.briefcase.reused.http.Http) Collectors.toList(java.util.stream.Collectors.toList) List(java.util.List) Stream(java.util.stream.Stream) PullFromAggregate(org.opendatakit.briefcase.pull.aggregate.PullFromAggregate) CacheUpdateEvent(org.opendatakit.briefcase.reused.CacheUpdateEvent) Optional(java.util.Optional) EventSubscriber(org.bushe.swing.event.annotation.EventSubscriber) ExportEvent(org.opendatakit.briefcase.export.ExportEvent) Analytics(org.opendatakit.briefcase.ui.reused.Analytics) Job(org.opendatakit.briefcase.reused.job.Job) ExportToCsv(org.opendatakit.briefcase.export.ExportToCsv) ExportConfiguration(org.opendatakit.briefcase.export.ExportConfiguration) EventBus(org.bushe.swing.event.EventBus) FormKey(org.opendatakit.briefcase.model.form.FormKey) FormMetadata(org.opendatakit.briefcase.model.form.FormMetadata) BriefcaseException(org.opendatakit.briefcase.reused.BriefcaseException) PullFromAggregate(org.opendatakit.briefcase.pull.aggregate.PullFromAggregate) Job(org.opendatakit.briefcase.reused.job.Job) FormDefinition(org.opendatakit.briefcase.export.FormDefinition) BriefcaseFormDefinition(org.opendatakit.briefcase.model.BriefcaseFormDefinition) AggregateServer(org.opendatakit.briefcase.reused.transfer.AggregateServer)

Example 2 with FormMetadataPort

use of org.opendatakit.briefcase.model.form.FormMetadataPort in project briefcase by opendatakit.

the class PullFormFromAggregate method pullFormFromAggregate.

public static void pullFormFromAggregate(Path storageDir, Optional<String> formId, String username, String password, URL server, boolean resumeLastPull, Optional<LocalDate> startFromDate, boolean includeIncomplete, Optional<Integer> maybeMaxHttpConnections) {
    CliEventsCompanion.attach(log);
    Path briefcaseDir = Common.getOrCreateBriefcaseDir(storageDir);
    FormCache formCache = FormCache.from(briefcaseDir);
    formCache.update();
    BriefcasePreferences appPreferences = BriefcasePreferences.appScoped();
    FormMetadataPort formMetadataPort = FileSystemFormMetadataAdapter.at(briefcaseDir);
    int maxHttpConnections = Optionals.race(maybeMaxHttpConnections, appPreferences.getMaxHttpConnections()).orElse(DEFAULT_HTTP_CONNECTIONS);
    Http http = appPreferences.getHttpProxy().map(host -> CommonsHttp.of(maxHttpConnections, host)).orElseGet(() -> CommonsHttp.of(maxHttpConnections));
    AggregateServer aggregateServer = AggregateServer.authenticated(server, new Credentials(username, password));
    Response<List<RemoteFormDefinition>> response = http.execute(aggregateServer.getFormListRequest());
    if (!response.isSuccess()) {
        System.err.println(response.isRedirection() ? "Error connecting to Aggregate: Redirection detected" : response.isUnauthorized() ? "Error connecting to Aggregate: Wrong credentials" : response.isNotFound() ? "Error connecting to Aggregate: Aggregate not found" : "Error connecting to Aggregate");
        return;
    }
    List<FormStatus> filteredForms = response.orElseThrow(BriefcaseException::new).stream().filter(f -> formId.map(id -> f.getFormId().equals(id)).orElse(true)).map(FormStatus::new).collect(toList());
    if (formId.isPresent() && filteredForms.isEmpty())
        throw new BriefcaseException("Form " + formId.get() + " not found");
    TransferForms forms = TransferForms.empty();
    forms.load(filteredForms);
    forms.selectAll();
    PullFromAggregate pullOp = new PullFromAggregate(http, aggregateServer, briefcaseDir, includeIncomplete, PullFormFromAggregate::onEvent, formMetadataPort);
    JobsRunner.launchAsync(forms.map(form -> pullOp.pull(form, resolveCursor(resumeLastPull, startFromDate, form, formMetadataPort))), PullFormFromAggregate::onError).waitForCompletion();
    System.out.println();
    System.out.println("All operations completed");
    System.out.println();
}
Also used : Path(java.nio.file.Path) Arrays(java.util.Arrays) FileSystemFormMetadataAdapter(org.opendatakit.briefcase.model.form.FileSystemFormMetadataAdapter) Credentials(org.opendatakit.briefcase.reused.http.Credentials) URL(java.net.URL) BriefcasePreferences(org.opendatakit.briefcase.model.BriefcasePreferences) Optionals(org.opendatakit.briefcase.reused.Optionals) Response(org.opendatakit.briefcase.reused.http.response.Response) LoggerFactory(org.slf4j.LoggerFactory) DEFAULT_HTTP_CONNECTIONS(org.opendatakit.briefcase.reused.http.Http.DEFAULT_HTTP_CONNECTIONS) MAX_HTTP_CONNECTIONS(org.opendatakit.briefcase.operations.Common.MAX_HTTP_CONNECTIONS) FORM_ID(org.opendatakit.briefcase.operations.Common.FORM_ID) Operation(org.opendatakit.common.cli.Operation) FormMetadataPort(org.opendatakit.briefcase.model.form.FormMetadataPort) BriefcaseException(org.opendatakit.briefcase.reused.BriefcaseException) AggregateServer(org.opendatakit.briefcase.reused.transfer.AggregateServer) TransferForms(org.opendatakit.briefcase.transfer.TransferForms) SERVER_URL(org.opendatakit.briefcase.operations.Common.SERVER_URL) CREDENTIALS_PASSWORD(org.opendatakit.briefcase.operations.Common.CREDENTIALS_PASSWORD) FormCache(org.opendatakit.briefcase.util.FormCache) Path(java.nio.file.Path) FormKey(org.opendatakit.briefcase.model.form.FormKey) CommonsHttp(org.opendatakit.briefcase.reused.http.CommonsHttp) RemoteFormDefinition(org.opendatakit.briefcase.model.RemoteFormDefinition) FormStatus(org.opendatakit.briefcase.model.FormStatus) FormStatusEvent(org.opendatakit.briefcase.model.FormStatusEvent) Logger(org.slf4j.Logger) FormMetadataQueries.lastCursorOf(org.opendatakit.briefcase.model.form.FormMetadataQueries.lastCursorOf) Param(org.opendatakit.common.cli.Param) Cursor(org.opendatakit.briefcase.pull.aggregate.Cursor) STORAGE_DIR(org.opendatakit.briefcase.operations.Common.STORAGE_DIR) JobsRunner(org.opendatakit.briefcase.reused.job.JobsRunner) Http(org.opendatakit.briefcase.reused.http.Http) CREDENTIALS_USERNAME(org.opendatakit.briefcase.operations.Common.CREDENTIALS_USERNAME) Collectors.toList(java.util.stream.Collectors.toList) List(java.util.List) PullFromAggregate(org.opendatakit.briefcase.pull.aggregate.PullFromAggregate) LocalDate(java.time.LocalDate) Optional(java.util.Optional) FormCache(org.opendatakit.briefcase.util.FormCache) BriefcasePreferences(org.opendatakit.briefcase.model.BriefcasePreferences) FormMetadataPort(org.opendatakit.briefcase.model.form.FormMetadataPort) CommonsHttp(org.opendatakit.briefcase.reused.http.CommonsHttp) Http(org.opendatakit.briefcase.reused.http.Http) BriefcaseException(org.opendatakit.briefcase.reused.BriefcaseException) PullFromAggregate(org.opendatakit.briefcase.pull.aggregate.PullFromAggregate) TransferForms(org.opendatakit.briefcase.transfer.TransferForms) FormStatus(org.opendatakit.briefcase.model.FormStatus) Collectors.toList(java.util.stream.Collectors.toList) List(java.util.List) AggregateServer(org.opendatakit.briefcase.reused.transfer.AggregateServer) Credentials(org.opendatakit.briefcase.reused.http.Credentials)

Example 3 with FormMetadataPort

use of org.opendatakit.briefcase.model.form.FormMetadataPort in project briefcase by opendatakit.

the class ImportFromODK method importODK.

public static void importODK(Path storageDir, Path odkDir, Optional<String> formId) {
    CliEventsCompanion.attach(log);
    Path briefcaseDir = Common.getOrCreateBriefcaseDir(storageDir);
    FormCache formCache = FormCache.from(briefcaseDir);
    formCache.update();
    FormMetadataPort formMetadataPort = FileSystemFormMetadataAdapter.at(briefcaseDir);
    TransferForms forms = TransferForms.from(FileSystemUtils.getODKFormList(odkDir.toFile()).stream().map(FormStatus::new).filter(form -> formId.map(id -> form.getFormDefinition().getFormId().equals(id)).orElse(true)).collect(toList()));
    forms.selectAll();
    if (formId.isPresent() && forms.isEmpty())
        throw new BriefcaseException("Form " + formId.get() + " not found");
    PullFromCollect.pullForms(formMetadataPort, forms, briefcaseDir, odkDir, ImportFromODK::onEvent).waitForCompletion();
}
Also used : Path(java.nio.file.Path) BriefcaseException(org.opendatakit.briefcase.reused.BriefcaseException) FormCache(org.opendatakit.briefcase.util.FormCache) FormMetadataPort(org.opendatakit.briefcase.model.form.FormMetadataPort) TransferForms(org.opendatakit.briefcase.transfer.TransferForms)

Example 4 with FormMetadataPort

use of org.opendatakit.briefcase.model.form.FormMetadataPort in project briefcase by opendatakit.

the class PullFormFromCentral method pullFromCentral.

private static void pullFromCentral(Args args) {
    CliEventsCompanion.attach(log);
    Path briefcaseDir = Common.getOrCreateBriefcaseDir(args.get(STORAGE_DIR));
    FormCache formCache = FormCache.from(briefcaseDir);
    formCache.update();
    BriefcasePreferences appPreferences = BriefcasePreferences.appScoped();
    FormMetadataPort formMetadataPort = FileSystemFormMetadataAdapter.at(briefcaseDir);
    int maxHttpConnections = Optionals.race(args.getOptional(MAX_HTTP_CONNECTIONS), appPreferences.getMaxHttpConnections()).orElse(DEFAULT_HTTP_CONNECTIONS);
    Http http = appPreferences.getHttpProxy().map(host -> CommonsHttp.of(maxHttpConnections, host)).orElseGet(() -> CommonsHttp.of(maxHttpConnections));
    CentralServer server = CentralServer.of(args.get(SERVER_URL), args.get(PROJECT_ID), new Credentials(args.get(CREDENTIALS_EMAIL), args.get(CREDENTIALS_PASSWORD)));
    String token = http.execute(server.getSessionTokenRequest()).orElseThrow(() -> new BriefcaseException("Can't authenticate with ODK Central"));
    Response<List<RemoteFormDefinition>> response = http.execute(server.getFormsListRequest(token));
    if (!response.isSuccess()) {
        System.err.println(response.isRedirection() ? "Error connecting to Central: Redirection detected" : response.isUnauthorized() ? "Error connecting to Central: Wrong credentials" : response.isNotFound() ? "Error connecting to Central: Central not found" : "Error connecting to Central");
        return;
    }
    Optional<String> formId = args.getOptional(FORM_ID);
    List<FormStatus> filteredForms = response.orElseThrow(BriefcaseException::new).stream().filter(f -> formId.map(id -> f.getFormId().equals(id)).orElse(true)).map(FormStatus::new).collect(toList());
    if (formId.isPresent() && filteredForms.isEmpty())
        throw new BriefcaseException("Form " + formId.get() + " not found");
    TransferForms forms = TransferForms.empty();
    forms.load(filteredForms);
    forms.selectAll();
    PullFromCentral pullOp = new PullFromCentral(http, server, briefcaseDir, token, PullFormFromCentral::onEvent, formMetadataPort);
    JobsRunner.launchAsync(forms.map(pullOp::pull), PullFormFromCentral::onError).waitForCompletion();
    System.out.println();
    System.out.println("All operations completed");
    System.out.println();
}
Also used : Path(java.nio.file.Path) Arrays(java.util.Arrays) FileSystemFormMetadataAdapter(org.opendatakit.briefcase.model.form.FileSystemFormMetadataAdapter) Credentials(org.opendatakit.briefcase.reused.http.Credentials) BriefcasePreferences(org.opendatakit.briefcase.model.BriefcasePreferences) Optionals(org.opendatakit.briefcase.reused.Optionals) Response(org.opendatakit.briefcase.reused.http.response.Response) LoggerFactory(org.slf4j.LoggerFactory) DEFAULT_HTTP_CONNECTIONS(org.opendatakit.briefcase.reused.http.Http.DEFAULT_HTTP_CONNECTIONS) MAX_HTTP_CONNECTIONS(org.opendatakit.briefcase.operations.Common.MAX_HTTP_CONNECTIONS) FORM_ID(org.opendatakit.briefcase.operations.Common.FORM_ID) Operation(org.opendatakit.common.cli.Operation) FormMetadataPort(org.opendatakit.briefcase.model.form.FormMetadataPort) BriefcaseException(org.opendatakit.briefcase.reused.BriefcaseException) TransferForms(org.opendatakit.briefcase.transfer.TransferForms) SERVER_URL(org.opendatakit.briefcase.operations.Common.SERVER_URL) CREDENTIALS_PASSWORD(org.opendatakit.briefcase.operations.Common.CREDENTIALS_PASSWORD) FormCache(org.opendatakit.briefcase.util.FormCache) Path(java.nio.file.Path) CommonsHttp(org.opendatakit.briefcase.reused.http.CommonsHttp) RemoteFormDefinition(org.opendatakit.briefcase.model.RemoteFormDefinition) FormStatus(org.opendatakit.briefcase.model.FormStatus) FormStatusEvent(org.opendatakit.briefcase.model.FormStatusEvent) CentralServer(org.opendatakit.briefcase.reused.transfer.CentralServer) Logger(org.slf4j.Logger) Param(org.opendatakit.common.cli.Param) STORAGE_DIR(org.opendatakit.briefcase.operations.Common.STORAGE_DIR) JobsRunner(org.opendatakit.briefcase.reused.job.JobsRunner) Http(org.opendatakit.briefcase.reused.http.Http) PullFromCentral(org.opendatakit.briefcase.pull.central.PullFromCentral) Collectors.toList(java.util.stream.Collectors.toList) PROJECT_ID(org.opendatakit.briefcase.operations.Common.PROJECT_ID) List(java.util.List) CREDENTIALS_EMAIL(org.opendatakit.briefcase.operations.Common.CREDENTIALS_EMAIL) Optional(java.util.Optional) Args(org.opendatakit.common.cli.Args) FormCache(org.opendatakit.briefcase.util.FormCache) BriefcasePreferences(org.opendatakit.briefcase.model.BriefcasePreferences) FormMetadataPort(org.opendatakit.briefcase.model.form.FormMetadataPort) PullFromCentral(org.opendatakit.briefcase.pull.central.PullFromCentral) CommonsHttp(org.opendatakit.briefcase.reused.http.CommonsHttp) Http(org.opendatakit.briefcase.reused.http.Http) BriefcaseException(org.opendatakit.briefcase.reused.BriefcaseException) TransferForms(org.opendatakit.briefcase.transfer.TransferForms) FormStatus(org.opendatakit.briefcase.model.FormStatus) CentralServer(org.opendatakit.briefcase.reused.transfer.CentralServer) Collectors.toList(java.util.stream.Collectors.toList) List(java.util.List) Credentials(org.opendatakit.briefcase.reused.http.Credentials)

Example 5 with FormMetadataPort

use of org.opendatakit.briefcase.model.form.FormMetadataPort in project briefcase by opendatakit.

the class ExportToCsv method export.

/**
 * Export a form's submissions into some CSV files.
 * <p>
 * If the form has repeat groups, each repeat group will be exported into a separate CSV file.
 *
 * @param formDef       the {@link FormDefinition} form definition of the form to be exported
 * @param configuration the {@link ExportConfiguration} export configuration
 * @return an {@link ExportOutcome} with the export operation's outcome
 * @see ExportConfiguration
 */
private static ExportOutcome export(FormMetadataPort formMetadataPort, FormMetadata formMetadata, FormStatus formStatus, FormDefinition formDef, Path briefcaseDir, ExportConfiguration configuration, Optional<Analytics> analytics) {
    // Create an export tracker object with the total number of submissions we have to export
    ExportProcessTracker exportTracker = new ExportProcessTracker(formDef);
    exportTracker.start();
    SubmissionExportErrorCallback onParsingError = buildParsingErrorCallback(configuration.getErrorsDir(formDef.getFormName()));
    SubmissionExportErrorCallback onInvalidSubmission = buildParsingErrorCallback(configuration.getErrorsDir(formDef.getFormName())).andThen((path, message) -> analytics.ifPresent(ga -> ga.event("Export", "Export", "invalid submission", null)));
    List<Path> submissionFiles = getListOfSubmissionFiles(formMetadata, formDef, configuration.getDateRange(), configuration.resolveSmartAppend(), onParsingError);
    exportTracker.trackTotal(submissionFiles.size());
    createDirectories(configuration.getExportDir());
    List<Csv> csvs = Csv.getCsvs(formDef, configuration);
    csvs.forEach(Csv::prepareOutputFiles);
    if (formDef.getModel().hasAuditField()) {
        Path audit = configuration.getAuditPath(formDef.getFormName());
        if (!exists(audit) || configuration.resolveOverwriteExistingFiles())
            write(audit, "instance ID, event, node, start, end\n", CREATE, WRITE, TRUNCATE_EXISTING);
    }
    // Generate csv lines grouped by the fqdn of the model they belong to
    Map<String, CsvLines> csvLinesPerModel = ExportTools.getValidSubmissions(formDef, configuration, submissionFiles, onParsingError, onInvalidSubmission).peek(s -> exportTracker.incAndReport()).flatMap(submission -> csvs.stream().map(Csv::getMapper).map(mapper -> mapper.apply(submission))).collect(groupingByConcurrent(CsvLines::getModelFqn, reducing(CsvLines.empty(), CsvLines::merge)));
    // TODO We should have an extra step to produce the side effect of writing media files to disk to avoid having side-effects while generating the CSV output of binary fields
    // Write lines to each output Csv
    csvs.forEach(csv -> csv.appendLines(Optional.ofNullable(csvLinesPerModel.get(csv.getModelFqn())).orElse(CsvLines.empty())));
    exportTracker.end();
    Optional.ofNullable(csvLinesPerModel.get(formDef.getModel().fqn())).orElse(CsvLines.empty()).getLastLine().ifPresent(line -> {
        formMetadataPort.execute(updateLastExportedSubmission(formMetadata.getKey(), line.getInstanceId(), line.getSubmissionDate(), OffsetDateTime.now(), briefcaseDir, formStatus.getFormDir(briefcaseDir)));
    });
    ExportOutcome exportOutcome = exportTracker.computeOutcome();
    if (exportOutcome == ALL_EXPORTED)
        EventBus.publish(ExportEvent.successForm(formDef, (int) exportTracker.total));
    if (exportOutcome == SOME_SKIPPED)
        EventBus.publish(ExportEvent.partialSuccessForm(formDef, (int) exportTracker.exported, (int) exportTracker.total));
    if (exportOutcome == ALL_SKIPPED)
        EventBus.publish(ExportEvent.failure(formDef, "All submissions have been skipped"));
    return exportOutcome;
}
Also used : UncheckedFiles.deleteRecursive(org.opendatakit.briefcase.reused.UncheckedFiles.deleteRecursive) TRUNCATE_EXISTING(java.nio.file.StandardOpenOption.TRUNCATE_EXISTING) LoggerFactory(org.slf4j.LoggerFactory) UncheckedFiles.copy(org.opendatakit.briefcase.reused.UncheckedFiles.copy) FormMetadataCommands.updateLastExportedSubmission(org.opendatakit.briefcase.model.form.FormMetadataCommands.updateLastExportedSubmission) ALL_EXPORTED(org.opendatakit.briefcase.export.ExportOutcome.ALL_EXPORTED) FormMetadataPort(org.opendatakit.briefcase.model.form.FormMetadataPort) EventBus(org.bushe.swing.event.EventBus) Map(java.util.Map) FormMetadata(org.opendatakit.briefcase.model.form.FormMetadata) ALL_SKIPPED(org.opendatakit.briefcase.export.ExportOutcome.ALL_SKIPPED) Path(java.nio.file.Path) WRITE(java.nio.file.StandardOpenOption.WRITE) SOME_SKIPPED(org.opendatakit.briefcase.export.ExportOutcome.SOME_SKIPPED) Collectors.groupingByConcurrent(java.util.stream.Collectors.groupingByConcurrent) FormStatus(org.opendatakit.briefcase.model.FormStatus) Logger(org.slf4j.Logger) Collectors.reducing(java.util.stream.Collectors.reducing) UncheckedFiles.createDirectories(org.opendatakit.briefcase.reused.UncheckedFiles.createDirectories) UncheckedFiles.exists(org.opendatakit.briefcase.reused.UncheckedFiles.exists) List(java.util.List) UncheckedFiles.write(org.opendatakit.briefcase.reused.UncheckedFiles.write) OffsetDateTime(java.time.OffsetDateTime) CREATE(java.nio.file.StandardOpenOption.CREATE) Optional(java.util.Optional) Analytics(org.opendatakit.briefcase.ui.reused.Analytics) SubmissionParser.getListOfSubmissionFiles(org.opendatakit.briefcase.export.SubmissionParser.getListOfSubmissionFiles) Path(java.nio.file.Path)

Aggregations

FormMetadataPort (org.opendatakit.briefcase.model.form.FormMetadataPort)8 Path (java.nio.file.Path)6 FormStatus (org.opendatakit.briefcase.model.FormStatus)6 List (java.util.List)5 Optional (java.util.Optional)5 Http (org.opendatakit.briefcase.reused.http.Http)5 Collectors.toList (java.util.stream.Collectors.toList)4 BriefcasePreferences (org.opendatakit.briefcase.model.BriefcasePreferences)4 FormStatusEvent (org.opendatakit.briefcase.model.FormStatusEvent)4 FileSystemFormMetadataAdapter (org.opendatakit.briefcase.model.form.FileSystemFormMetadataAdapter)4 FormKey (org.opendatakit.briefcase.model.form.FormKey)4 BriefcaseException (org.opendatakit.briefcase.reused.BriefcaseException)4 FormCache (org.opendatakit.briefcase.util.FormCache)4 Arrays (java.util.Arrays)3 EventBus (org.bushe.swing.event.EventBus)3 FormMetadata (org.opendatakit.briefcase.model.form.FormMetadata)3 FORM_ID (org.opendatakit.briefcase.operations.Common.FORM_ID)3 STORAGE_DIR (org.opendatakit.briefcase.operations.Common.STORAGE_DIR)3 JobsRunner (org.opendatakit.briefcase.reused.job.JobsRunner)3 TransferForms (org.opendatakit.briefcase.transfer.TransferForms)3