Search in sources :

Example 1 with ExportListenerImpl

use of com.enonic.xp.impl.server.rest.task.listener.ExportListenerImpl in project xp by enonic.

the class ExportRunnableTask method run.

@Override
public void run(final TaskId id, final ProgressReporter progressReporter) {
    final NodeExportResult result = getContext(params.getSourceRepoPath()).callWith(() -> this.exportService.exportNodes(ExportNodesParams.create().sourceNodePath(params.getSourceRepoPath().getNodePath()).exportName(params.getExportName()).dryRun(params.isDryRun()).includeNodeIds(params.isExportWithIds()).includeVersions(params.isIncludeVersions()).nodeExportListener(new ExportListenerImpl(progressReporter)).build()));
    progressReporter.info(NodeExportResultJson.from(result).toString());
}
Also used : ExportListenerImpl(com.enonic.xp.impl.server.rest.task.listener.ExportListenerImpl) NodeExportResult(com.enonic.xp.export.NodeExportResult)

Aggregations

NodeExportResult (com.enonic.xp.export.NodeExportResult)1 ExportListenerImpl (com.enonic.xp.impl.server.rest.task.listener.ExportListenerImpl)1