Package uk.ac.starlink.task
Class MultiTaskInvoker
java.lang.Object
uk.ac.starlink.task.MultiTaskInvoker
Invokes tasks from a command line when the tasks are available from
an
ObjectFactory.- Since:
- 23 Jan 2007
- Author:
- Mark Taylor
-
Constructor Summary
ConstructorsConstructorDescriptionMultiTaskInvoker(String toolName, uk.ac.starlink.util.ObjectFactory<Task> taskFactory) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionReturns the message to be reported if the "-version" flag is given.intInvokes one of the tasks known by this invoker given a command line.voidsetVersionMessage(String msg) Sets the message which will be reported if the "-version" flag is given.
-
Constructor Details
-
MultiTaskInvoker
Constructor.- Parameters:
toolName- user-known name for the tooltaskFactory- lists available tasks
-
-
Method Details
-
invoke
Invokes one of the tasks known by this invoker given a command line. The commmand line is an array of words of the form[<flags>] <taskname> [<task-args>]- Parameters:
args- command line words
-
setVersionMessage
Sets the message which will be reported if the "-version" flag is given.- Parameters:
msg- formatted version message
-
getVersionMessage
Returns the message to be reported if the "-version" flag is given.- Returns:
- formatted version message
-