public class CommandLineImporter extends Object
Modifier and Type | Field and Description |
---|---|
ImportConfig |
config
Configuration used by all components
|
static int |
DEFAULT_WAIT |
List<FileExclusion> |
exclusions
FileExclusion mechanisms for skipping candidates |
ErrorHandler |
handler
ErrorHandler which is also responsible for uploading files
|
ImportLibrary |
library
Base importer library, this is what we actually use to import.
|
FileTransfer |
transfer
FileTransfer mechanism to be used for uploading |
Constructor and Description |
---|
CommandLineImporter(ImportConfig config,
String[] paths,
boolean getUsedFiles)
Legacy constructor which uses a
UploadFileTransfer . |
CommandLineImporter(ImportConfig config,
String[] paths,
boolean getUsedFiles,
FileTransfer transfer,
int minutesToWait)
Legacy constructor without any file exclusions.
|
CommandLineImporter(ImportConfig config,
String[] paths,
boolean getUsedFiles,
FileTransfer transfer,
List<FileExclusion> exclusions,
int minutesToWait)
Main entry class for the application.
|
Modifier and Type | Method and Description |
---|---|
static void |
advUsage()
Prints advanced usage to STDERR and exits with return code 1.
|
void |
cleanup()
Cleans up after a successful or unsuccessful image import.
|
static int |
closeCompleted(ImportConfig config)
Look for all
ImportProcessPrx in the current session and close
them if they return a non-null Response (i.e. they are done). |
static void |
main(String[] args)
Command line application entry point which parses CLI arguments and
passes them into the importer.
|
static void |
setArgument(Map<String,Boolean> map,
String key)
Set a conflicting argument and return the usage if the key is already
set
|
int |
start() |
static void |
usage()
Prints usage to STDERR and exits with return code 1.
|
static int |
waitCompleted(ImportConfig config)
Look for all
ImportProcessPrx in the current session and close
them if they return a non-null Response (i.e. they are done). |
public static final int DEFAULT_WAIT
public final ImportConfig config
public final FileTransfer transfer
FileTransfer
mechanism to be used for uploadingpublic final List<FileExclusion> exclusions
FileExclusion
mechanisms for skipping candidatespublic final ImportLibrary library
public final ErrorHandler handler
public CommandLineImporter(ImportConfig config, String[] paths, boolean getUsedFiles) throws Exception
UploadFileTransfer
.Exception
public CommandLineImporter(ImportConfig config, String[] paths, boolean getUsedFiles, FileTransfer transfer, int minutesToWait) throws Exception
Exception
public CommandLineImporter(ImportConfig config, String[] paths, boolean getUsedFiles, FileTransfer transfer, List<FileExclusion> exclusions, int minutesToWait) throws Exception
Exception
public static int closeCompleted(ImportConfig config) throws Exception
ImportProcessPrx
in the current session and close
them if they return a non-null Response
(i.e. they are done).Exception
public static int waitCompleted(ImportConfig config) throws Exception
ImportProcessPrx
in the current session and close
them if they return a non-null Response
(i.e. they are done).Exception
public int start()
public void cleanup()
public static void usage()
public static void advUsage()
public static void main(String[] args) throws Exception
args
- Command line arguments.Exception
Version: 5.1.4-ice35-b55
Copyright © 2015 The University of Dundee & Open Microscopy Environment. All Rights Reserved.