Package edu.isi.pegasus.planner.dax
Class AbstractJob
- java.lang.Object
-
- edu.isi.pegasus.planner.dax.AbstractJob
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AbstractJob.JsonSerializer
Custom serializer for YAML representation of AbstractJob
-
Field Summary
Fields Modifier and Type Field Description private static java.lang.String
ARG_DELIMITER
private static java.lang.String
FILE_DELIMITER
private static java.lang.String
JOBTYPE
protected java.util.List
mArguments
protected java.lang.String
mId
protected java.util.List<Invoke>
mInvokes
protected static edu.isi.pegasus.common.logging.LogManager
mLogger
private java.util.Set<MetaData>
mMetaDataAttributes
The metadata attributes associated with the whole workflow.protected java.lang.String
mName
protected java.lang.String
mNamespace
protected java.lang.String
mNodeLabel
protected java.util.List<Profile>
mProfiles
protected File
mStderr
protected File
mStdin
protected File
mStdout
protected java.util.Set<File>
mUses
protected java.lang.String
mVersion
-
Constructor Summary
Constructors Modifier Constructor Description protected
AbstractJob()
protected
AbstractJob(AbstractJob a)
Copy constructor
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description AbstractJob
addArgument(File file)
Add a file object to the argument List.AbstractJob
addArgument(File[] files)
Add a Array ofFile
objects to the argument list.AbstractJob
addArgument(File[] files, java.lang.String filedelimiter)
Deprecated.As of 5.0.2 release this function will not work consistently as ARG_LIMITER is always added between argsAbstractJob
addArgument(java.lang.String argument)
Add a string argument to the argument List.AbstractJob
addArgument(java.lang.String argkey, File argvalue)
Add a argument key and File value to the argument List.
The argkey and argvalue are seperated by space.
Example addArgument("-i",new File("f.a")) will result in the argument being added as -i <file name="f.a">
Multiple calls to addArgument results in the arguments being separated by space.AbstractJob
addArgument(java.lang.String argkey, File[] argvalue)
Add a argument key and an array of Files to the argument List.
The argkey and argvalue are separated space.
The files are separated by a space
Example:
File[] files = {new File("f.a1"), new File("f.a2")};
job.addArgument("-i",files)
will result in the argument being added as -i <file name="f.a1"> <file name="f.a2">
Multiple calls to addArgument results in the arguments being separated by space.AbstractJob
addArgument(java.lang.String argkey, File[] argvalue, java.lang.String argdelimiter, java.lang.String filedelimiter)
Add a argument key and an array of Files to the argument List.
The argkey and argvalue are separated by the argdelimiter.
The files are separated by a filedelimiter
Example:
File[] files = {new File("f.a1"), new File("f.a2")};
job.addArgument("-i",files,"=",",")
will result in the argument being added as -i=<file name="f.a1">,<file name="f.a2">
Multiple calls to addArgument results in the arguments being separated by space.AbstractJob
addArgument(java.lang.String argkey, File argvalue, java.lang.String argdelimiter)
Add a argument key and File value to the argument List.
The argkey and argvalue are separated by the argdelimiter.
Example addArgument("-i",new File("f.a"),"=") will result in the argument being added as -i=<file name="f.a">
Multiple calls to addArgument results in the arguments being separated by space.AbstractJob
addArgument(java.lang.String argkey, java.lang.String argvalue)
Add a argument key and value to the argument List.AbstractJob
addArgument(java.lang.String argkey, java.lang.String argvalue, java.lang.String argdelimiter)
Add a argument key and value to the argument List.
The argkey and argvalue are seperated by argdelimiter.
Example addArgument("-p","0","=") will result in the argument being added as -p=0
Multiple calls to addArgument results in the arguments being separated by space.AbstractJob
addArgument(java.lang.String argkey, java.util.List<File> argvalue)
Add a argument key and a List of Files to the argument List.
The argkey and argvalue are separated space.
The files are separated by a space
Example:AbstractJob
addArgument(java.lang.String argkey, java.util.List<File> argvalue, java.lang.String argdelimiter, java.lang.String filedelimiter)
Add a argument key and a List of Files to the argument List.
The argkey and argvalue are separated by the argdelimiter.
The files are separated by a filedelimter
Example:
List<File> files = new LinkedList<File>(); files.add(new File("f.a1")); files.add(new File("f.a2")); job.addArgument("-i",files,"=",",")
will result in the argument being added as -i=<file name="f.a1">,<file name="f.a2">
Multiple calls to addArgument results in the arguments being separated by space.AbstractJob
addArgument(java.util.List<File> files)
Add a List ofFile
objects to the argument list.AbstractJob
addArgument(java.util.List<File> files, java.lang.String filedelimiter)
Deprecated.As of 5.0.2 release this function will not work consistently as ARG_LIMITER is always added between argsAbstractJob
addInvoke(Invoke invoke)
Add notification to the jobAbstractJob
addInvoke(Invoke.WHEN when, java.lang.String what)
Add Notification to the jobAbstractJob
addInvokes(java.util.List<Invoke> invokes)
Add Notifications to the jobAbstractJob
addMetaData(java.lang.String key, java.lang.String value)
Adds metadata to the workflowAbstractJob
addNotification(Invoke invoke)
Add notification to the jobAbstractJob
addNotification(Invoke.WHEN when, java.lang.String what)
Add Notification to the jobAbstractJob
addNotifications(java.util.List<Invoke> invokes)
Add Notifications to the jobAbstractJob
addProfile(Profile profile)
Add a Profile objectAbstractJob
addProfile(Profile.NAMESPACE namespace, java.lang.String key, java.lang.String value)
Add a profile to the jobAbstractJob
addProfile(java.lang.String namespace, java.lang.String key, java.lang.String value)
Add a profile to the jobAbstractJob
addProfiles(java.util.List<Profile> profiles)
Add a list of Profile objectsprotected static void
checkID(java.lang.String id)
Copy Constructorboolean
equals(java.lang.Object obj)
java.util.List
getArguments()
Return the argument List.java.lang.String
getId()
java.util.List<Invoke>
getInvoke()
Returns list of Invoke objectsjava.lang.String
getMetaData(java.lang.String key)
Returns the metadata associated for a key if exists, else nulljava.lang.String
getName()
java.lang.String
getNodeLabel()
java.util.List<Invoke>
getNotification()
Same as getInvoke().java.util.List
getProfiles()
Return the profile List.File
getStderr()
File
getStdin()
Get the STDIN file objectFile
getStdout()
java.util.Set<File>
getUses()
int
hashCode()
boolean
isDAG()
Is this Object a DAGboolean
isDAX()
Is this Object a DAXboolean
isJob()
Is this Object a Jobvoid
setNodeLabel(java.lang.String label)
AbstractJob
setStderr(File stderr)
AbstractJob
setStderr(File stderr, boolean register)
AbstractJob
setStderr(File stderr, File.TRANSFER transfer)
AbstractJob
setStderr(File stderr, File.TRANSFER transfer, boolean register)
AbstractJob
setStderr(File stderr, File.TRANSFER transfer, boolean register, boolean optional)
AbstractJob
setStderr(java.lang.String stderr)
AbstractJob
setStderr(java.lang.String stderr, boolean register)
AbstractJob
setStderr(java.lang.String stderr, File.TRANSFER transfer)
AbstractJob
setStderr(java.lang.String stderr, File.TRANSFER transfer, boolean register)
AbstractJob
setStderr(java.lang.String stderr, File.TRANSFER transfer, boolean register, boolean optional)
AbstractJob
setStdin(File stdin)
AbstractJob
setStdin(File stdin, boolean register)
AbstractJob
setStdin(File stdin, File.TRANSFER transfer)
AbstractJob
setStdin(File stdin, File.TRANSFER transfer, boolean register)
AbstractJob
setStdin(File stdin, File.TRANSFER transfer, boolean register, boolean optional)
AbstractJob
setStdin(java.lang.String stdin)
AbstractJob
setStdin(java.lang.String stdin, boolean register)
AbstractJob
setStdin(java.lang.String stdin, File.TRANSFER transfer)
AbstractJob
setStdin(java.lang.String stdin, File.TRANSFER transfer, boolean register)
AbstractJob
setStdin(java.lang.String stdin, File.TRANSFER transfer, boolean register, boolean optional)
AbstractJob
setStdout(File stdout)
AbstractJob
setStdout(File stdout, boolean register)
AbstractJob
setStdout(File stdout, File.TRANSFER transfer)
AbstractJob
setStdout(File stdout, File.TRANSFER transfer, boolean register)
AbstractJob
setStdout(File stdout, File.TRANSFER transfer, boolean register, boolean optional)
AbstractJob
setStdout(java.lang.String stdout)
AbstractJob
setStdout(java.lang.String stdout, boolean register)
AbstractJob
setStdout(java.lang.String stdout, File.TRANSFER transfer)
AbstractJob
setStdout(java.lang.String stdout, File.TRANSFER transfer, boolean register)
AbstractJob
setStdout(java.lang.String stdout, File.TRANSFER transfer, boolean register, boolean optional)
void
toXML(edu.isi.pegasus.common.util.XMLWriter writer)
void
toXML(edu.isi.pegasus.common.util.XMLWriter writer, int indent)
AbstractJob
uses(File file, File.LINK link)
AbstractJob
uses(File file, File.LINK link, boolean register)
AbstractJob
uses(File file, File.LINK link, boolean register, java.lang.String size)
AbstractJob
uses(File file, File.LINK link, File.TRANSFER transfer)
AbstractJob
uses(File file, File.LINK link, File.TRANSFER transfer, boolean register)
AbstractJob
uses(File file, File.LINK link, File.TRANSFER transfer, boolean register, boolean forPlanning)
AbstractJob
uses(File file, File.LINK link, File.TRANSFER transfer, boolean register, boolean optional, boolean executable)
AbstractJob
uses(File file, File.LINK link, File.TRANSFER transfer, boolean register, boolean optional, boolean executable, java.lang.String size)
AbstractJob
uses(File file, File.LINK link, File.TRANSFER transfer, boolean register, java.lang.String size)
AbstractJob
uses(File file, File.LINK link, File.TRANSFER transfer, java.lang.String size)
AbstractJob
uses(File file, File.LINK link, java.lang.String size)
AbstractJob
uses(java.lang.String file, File.LINK link)
AbstractJob
uses(java.lang.String file, File.LINK link, boolean register)
AbstractJob
uses(java.lang.String file, File.LINK link, boolean register, java.lang.String size)
AbstractJob
uses(java.lang.String file, File.LINK link, File.TRANSFER transfer)
AbstractJob
uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, boolean register)
AbstractJob
uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, boolean register, boolean forPlanning)
AbstractJob
uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, boolean register, boolean optional, boolean executable)
AbstractJob
uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, boolean register, boolean optional, boolean executable, java.lang.String size)
AbstractJob
uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, boolean register, java.lang.String size)
AbstractJob
uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, java.lang.String size)
AbstractJob
uses(java.lang.String file, File.LINK link, java.lang.String size)
AbstractJob
uses(java.util.List<File> files, File.LINK link)
-
-
-
Field Detail
-
mArguments
protected java.util.List mArguments
-
mProfiles
protected java.util.List<Profile> mProfiles
-
mStdin
protected File mStdin
-
mStdout
protected File mStdout
-
mStderr
protected File mStderr
-
mUses
protected java.util.Set<File> mUses
-
mInvokes
protected java.util.List<Invoke> mInvokes
-
mName
protected java.lang.String mName
-
mId
protected java.lang.String mId
-
mNamespace
protected java.lang.String mNamespace
-
mVersion
protected java.lang.String mVersion
-
mNodeLabel
protected java.lang.String mNodeLabel
-
mMetaDataAttributes
private java.util.Set<MetaData> mMetaDataAttributes
The metadata attributes associated with the whole workflow.
-
mLogger
protected static edu.isi.pegasus.common.logging.LogManager mLogger
-
ARG_DELIMITER
private static final java.lang.String ARG_DELIMITER
- See Also:
- Constant Field Values
-
FILE_DELIMITER
private static final java.lang.String FILE_DELIMITER
- See Also:
- Constant Field Values
-
JOBTYPE
private static final java.lang.String JOBTYPE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
AbstractJob
protected AbstractJob()
-
AbstractJob
protected AbstractJob(AbstractJob a)
Copy constructor- Parameters:
a
- the job
-
-
Method Detail
-
checkID
protected static void checkID(java.lang.String id)
Copy Constructor- Parameters:
id
- the string id
-
getArguments
public java.util.List getArguments()
Return the argument List. The List contains bothString
as well asFile
objects- Returns:
- List
-
addArgument
public AbstractJob addArgument(java.lang.String argument)
Add a string argument to the argument List. Each call to argument adds a space in between entries- Parameters:
argument
- argument to the job- Returns:
- AbstractJob
-
addArgument
public AbstractJob addArgument(File file)
Add a file object to the argument List. Each call to argument adds a space between entries.- Parameters:
file
- the file- Returns:
- AbstractJob
- See Also:
File
-
addArgument
public AbstractJob addArgument(File[] files)
Add a Array ofFile
objects to the argument list. The files will be separated by space when rendered on the command line- Parameters:
files
- File[]- Returns:
- AbstractJob
- See Also:
File
-
addArgument
public AbstractJob addArgument(java.util.List<File> files)
Add a List ofFile
objects to the argument list. The files will be separated by space when rendered on the command line- Parameters:
files
- List of File objects- Returns:
- AbstractJob
- See Also:
File
-
addArgument
public AbstractJob addArgument(File[] files, java.lang.String filedelimiter)
Deprecated.As of 5.0.2 release this function will not work consistently as ARG_LIMITER is always added between argsAdd a Array ofFile
objects to the argument list. The files will be separated by the filedelimiter(default is space) when rendered on the command line.- Parameters:
files
- File[] Array of file objectsfiledelimiter
- String delimiter for the files. Default is space- Returns:
- AbstractJob
- See Also:
File
-
addArgument
public AbstractJob addArgument(java.util.List<File> files, java.lang.String filedelimiter)
Deprecated.As of 5.0.2 release this function will not work consistently as ARG_LIMITER is always added between argsAdd a List ofFile
objects to the argument list. The files will be separated by the filedelimiter(default is space) when rendered on the command line.- Parameters:
files
- List of File objectsfiledelimiter
- String delimiter for the files. Default is space- Returns:
- AbstractJob
- See Also:
File
-
addArgument
public AbstractJob addArgument(java.lang.String argkey, java.lang.String argvalue)
Add a argument key and value to the argument List. The argkey and argvalue are seperated by space. Example addArgument("-p","0") will result in the argument being added as -p 0
Multiple calls to addArgument results in the arguments being separated by space.- Parameters:
argkey
- Stringargvalue
- String- Returns:
- AbstractJob
-
addArgument
public AbstractJob addArgument(java.lang.String argkey, java.lang.String argvalue, java.lang.String argdelimiter)
Add a argument key and value to the argument List.
The argkey and argvalue are seperated by argdelimiter.
Example addArgument("-p","0","=") will result in the argument being added as -p=0
Multiple calls to addArgument results in the arguments being separated by space.- Parameters:
argkey
- String Keyargvalue
- String Valueargdelimiter
- String argdelimiter- Returns:
- AbstractJob
-
addArgument
public AbstractJob addArgument(java.lang.String argkey, File argvalue)
Add a argument key and File value to the argument List.
The argkey and argvalue are seperated by space.
Example addArgument("-i",new File("f.a")) will result in the argument being added as -i <file name="f.a">
Multiple calls to addArgument results in the arguments being separated by space.- Parameters:
argkey
- Stringargvalue
- File- Returns:
- AbstractJob
-
addArgument
public AbstractJob addArgument(java.lang.String argkey, File argvalue, java.lang.String argdelimiter)
Add a argument key and File value to the argument List.
The argkey and argvalue are separated by the argdelimiter.
Example addArgument("-i",new File("f.a"),"=") will result in the argument being added as -i=<file name="f.a">
Multiple calls to addArgument results in the arguments being separated by space.- Parameters:
argkey
- Stringargvalue
- Fileargdelimiter
- argumenet delimiter- Returns:
- AbstractJob
-
addArgument
public AbstractJob addArgument(java.lang.String argkey, File[] argvalue)
Add a argument key and an array of Files to the argument List.
The argkey and argvalue are separated space.
The files are separated by a space
Example:
File[] files = {new File("f.a1"), new File("f.a2")};
job.addArgument("-i",files)
will result in the argument being added as -i <file name="f.a1"> <file name="f.a2">
Multiple calls to addArgument results in the arguments being separated by space.- Parameters:
argkey
- Stringargvalue
- File[]- Returns:
- AbstractJob
-
addArgument
public AbstractJob addArgument(java.lang.String argkey, java.util.List<File> argvalue)
Add a argument key and a List of Files to the argument List.
The argkey and argvalue are separated space.
The files are separated by a space
Example:
Multiple calls to addArgument results in the arguments being separated by space.List<File> files = new LinkedList<File>(); files.add(new File("f.a1")); files.add(new File("f.a2")); job.addArgument("-i",files)
will result in the argument being added as -i <file name="f.a1"> <file name="f.a2">
- Parameters:
argkey
- Stringargvalue
- list of files to be passed as arguments- Returns:
- AbstractJob
-
addArgument
public AbstractJob addArgument(java.lang.String argkey, File[] argvalue, java.lang.String argdelimiter, java.lang.String filedelimiter)
Add a argument key and an array of Files to the argument List.
The argkey and argvalue are separated by the argdelimiter.
The files are separated by a filedelimiter
Example:
File[] files = {new File("f.a1"), new File("f.a2")};
job.addArgument("-i",files,"=",",")
will result in the argument being added as -i=<file name="f.a1">,<file name="f.a2">
Multiple calls to addArgument results in the arguments being separated by space.- Parameters:
argkey
- Stringargvalue
- File[]argdelimiter
- Stringfiledelimiter
- String- Returns:
- AbstractJob
-
addArgument
public AbstractJob addArgument(java.lang.String argkey, java.util.List<File> argvalue, java.lang.String argdelimiter, java.lang.String filedelimiter)
Add a argument key and a List of Files to the argument List.
The argkey and argvalue are separated by the argdelimiter.
The files are separated by a filedelimter
Example:
List<File> files = new LinkedList<File>(); files.add(new File("f.a1")); files.add(new File("f.a2")); job.addArgument("-i",files,"=",",")
will result in the argument being added as -i=<file name="f.a1">,<file name="f.a2">
Multiple calls to addArgument results in the arguments being separated by space.- Parameters:
argkey
- Stringargvalue
- List<File> List of File objectsargdelimiter
- Stringfiledelimiter
- String- Returns:
- AbstractJob
-
addProfile
public AbstractJob addProfile(java.lang.String namespace, java.lang.String key, java.lang.String value)
Add a profile to the job- Parameters:
namespace
- Stringkey
- Stringvalue
- String- Returns:
- AbstractJob
-
addProfile
public AbstractJob addProfile(Profile.NAMESPACE namespace, java.lang.String key, java.lang.String value)
Add a profile to the job- Parameters:
namespace
-Profile.NAMESPACE
key
- Stringvalue
- String- Returns:
- AbstractJob
-
addProfile
public AbstractJob addProfile(Profile profile)
Add a Profile object- Parameters:
profile
- the profile to add- Returns:
- AbstractJob
- See Also:
Profile
-
addProfiles
public AbstractJob addProfiles(java.util.List<Profile> profiles)
Add a list of Profile objects- Parameters:
profiles
- List<Profile>- Returns:
- AbstractJob
-
getProfiles
public java.util.List getProfiles()
Return the profile List. The List contains bothProfile
objects- Returns:
- List
-
getStdin
public File getStdin()
Get the STDIN file object- Returns:
- File
-
setStdin
public AbstractJob setStdin(File stdin)
- Parameters:
stdin
- file object corresponding to the stdin of the file- Returns:
- AbstractJob
-
setStdin
public AbstractJob setStdin(File stdin, File.TRANSFER transfer)
- Parameters:
stdin
- file object corresponding to the stdin of the filetransfer
- the transfer flag to associate with stdin.- Returns:
- AbstractJob
-
setStdin
public AbstractJob setStdin(File stdin, boolean register)
- Parameters:
stdin
- File object corresponding to the stdin of the fileregister
- the register flag- Returns:
- AbstractJob
-
setStdin
public AbstractJob setStdin(File stdin, File.TRANSFER transfer, boolean register)
- Parameters:
stdin
- File object corresponding to the stdin of the filetransfer
- the transfer flag for stdinregister
- the register flag for the stdin- Returns:
- AbstractJob
-
setStdin
public AbstractJob setStdin(File stdin, File.TRANSFER transfer, boolean register, boolean optional)
- Parameters:
stdin
- File object corresponding to the stdin of the filetransfer
- the transfer flag for stdinregister
- the register flag for the stdinoptional
- boolean indicating file is optional- Returns:
- AbstractJob
-
setStdin
public AbstractJob setStdin(java.lang.String stdin)
- Parameters:
stdin
- File object corresponding to the stdin of the file- Returns:
- AbstractJob
-
setStdin
public AbstractJob setStdin(java.lang.String stdin, File.TRANSFER transfer)
- Parameters:
stdin
- File object corresponding to the stdin of the filetransfer
- transfer flag associated with the stdin- Returns:
- AbstractJob
-
setStdin
public AbstractJob setStdin(java.lang.String stdin, boolean register)
- Parameters:
stdin
- File object corresponding to the stdin of the fileregister
- the register flag- Returns:
- AbstractJob
-
setStdin
public AbstractJob setStdin(java.lang.String stdin, File.TRANSFER transfer, boolean register)
- Parameters:
stdin
- File object corresponding to the stdin of the filetransfer
- the transfer flag for stdinregister
- boolean register flag for the stdin- Returns:
- AbstractJob
-
setStdin
public AbstractJob setStdin(java.lang.String stdin, File.TRANSFER transfer, boolean register, boolean optional)
- Parameters:
stdin
- File object corresponding to the stdin of the filetransfer
- the transfer flag for stdinregister
- boolean register flag for the stdinoptional
- boolean indicating whether file is optional or not.- Returns:
- AbstractJob
-
getStdout
public File getStdout()
- Returns:
- File
-
setStdout
public AbstractJob setStdout(File stdout)
- Parameters:
stdout
- File object corresponding to the stdout of the job- Returns:
- AbstractJob
-
setStdout
public AbstractJob setStdout(File stdout, File.TRANSFER transfer)
- Parameters:
stdout
- File object corresponding to the stdout of the jobtransfer
- transfer flag- Returns:
- AbstractJob
-
setStdout
public AbstractJob setStdout(File stdout, boolean register)
- Parameters:
stdout
- File object corresponding to the stdout of the jobregister
- boolean to indicate whether to register stdout or not- Returns:
- AbstractJob
-
setStdout
public AbstractJob setStdout(File stdout, File.TRANSFER transfer, boolean register)
- Parameters:
stdout
- File object corresponding to the stdout of the jobtransfer
- transfer flag for stdoutregister
- boolean to indicate whether to register stdout or not- Returns:
- AbstractJob
-
setStdout
public AbstractJob setStdout(File stdout, File.TRANSFER transfer, boolean register, boolean optional)
- Parameters:
stdout
- File object corresponding to the stdout of the jobtransfer
- transfer flag for stdoutregister
- boolean to indicate whether to register stdout or notoptional
- boolean to indicate whether file is optional or not.- Returns:
- AbstractJob
-
setStdout
public AbstractJob setStdout(java.lang.String stdout)
- Parameters:
stdout
- name of the file to which stdout should be redirected to- Returns:
- AbstractJob
-
setStdout
public AbstractJob setStdout(java.lang.String stdout, File.TRANSFER transfer)
- Parameters:
stdout
- File object corresponding to the stdout of the jobtransfer
- transfer flag for stdout- Returns:
- AbstractJob
-
setStdout
public AbstractJob setStdout(java.lang.String stdout, boolean register)
- Parameters:
stdout
- File object corresponding to the stdout of the jobregister
- boolean to indicate whether to register stdout or not- Returns:
- AbstractJob
-
setStdout
public AbstractJob setStdout(java.lang.String stdout, File.TRANSFER transfer, boolean register)
- Parameters:
stdout
- File object corresponding to the stdout of the jobtransfer
- transfer flag for stdoutregister
- boolean to indicate whether to register stdout or not- Returns:
- AbstractJob
-
setStdout
public AbstractJob setStdout(java.lang.String stdout, File.TRANSFER transfer, boolean register, boolean optional)
- Parameters:
stdout
- File object corresponding to the stdout of the jobtransfer
- transfer flag for stdoutregister
- boolean to indicate whether to register stdout or notoptional
- indicate whether file is optional or not.- Returns:
- AbstractJob
-
getStderr
public File getStderr()
- Returns:
- File
-
setStderr
public AbstractJob setStderr(File stderr)
- Parameters:
stderr
- File object corresponding to the stderr of the job- Returns:
- AbstractJob
-
setStderr
public AbstractJob setStderr(File stderr, File.TRANSFER transfer)
- Parameters:
stderr
- File object corresponding to the stderr of the jobtransfer
- transfer flag for stderr- Returns:
- AbstractJob
-
setStderr
public AbstractJob setStderr(File stderr, boolean register)
- Parameters:
stderr
- File object corresponding to the stderr of the jobregister
- boolean to indicate whether to register stederr or not- Returns:
- AbstractJob
-
setStderr
public AbstractJob setStderr(File stderr, File.TRANSFER transfer, boolean register)
- Parameters:
stderr
- File object corresponding to the stderr of the jobtransfer
- transfer flag for stderrregister
- boolean to indicate whether to register stederr or not- Returns:
- AbstractJob
-
setStderr
public AbstractJob setStderr(File stderr, File.TRANSFER transfer, boolean register, boolean optional)
- Parameters:
stderr
- File object corresponding to the stderr of the jobtransfer
- transfer flag for stderrregister
- boolean to indicate whether to register stederr or notoptional
- boolean to indicate whether file is optional or not- Returns:
- AbstractJob
-
setStderr
public AbstractJob setStderr(java.lang.String stderr)
- Parameters:
stderr
- name of file to which stderr of the job should be redirected to- Returns:
- AbstractJob
-
setStderr
public AbstractJob setStderr(java.lang.String stderr, File.TRANSFER transfer)
- Parameters:
stderr
- name of the file to which stderr should be redirected totransfer
- transfer flag for stderr- Returns:
- AbstractJob
-
setStderr
public AbstractJob setStderr(java.lang.String stderr, boolean register)
- Parameters:
stderr
- name of the file to which stderr should be redirected toregister
- boolean to indicate whether to register stederr or not- Returns:
- AbstractJob
-
setStderr
public AbstractJob setStderr(java.lang.String stderr, File.TRANSFER transfer, boolean register)
- Parameters:
stderr
- name of the file to which stderr should be redirected totransfer
- transfer flag for stderrregister
- boolean to indicate whether to register stederr or not- Returns:
- AbstractJob
-
setStderr
public AbstractJob setStderr(java.lang.String stderr, File.TRANSFER transfer, boolean register, boolean optional)
- Parameters:
stderr
- name of the file to which stderr should be redirected totransfer
- transfer flag for stderrregister
- boolean to indicate whether to register stederr or notoptional
- boolean indicating whether file is optional or not- Returns:
- AbstractJob
-
getUses
public java.util.Set<File> getUses()
- Returns:
- Set of File objects
-
uses
public AbstractJob uses(java.lang.String file, File.LINK link)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or output- Returns:
- AbstractJob
-
uses
public AbstractJob uses(java.lang.String file, File.LINK link, boolean register)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputregister
- boolean indicating whether file should be registered or not- Returns:
- AbstractJob
-
uses
public AbstractJob uses(java.lang.String file, File.LINK link, boolean register, java.lang.String size)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputregister
- boolean indicating whether file should be registered or notsize
- size of the file- Returns:
- AbstractJob
-
uses
public AbstractJob uses(java.lang.String file, File.LINK link, java.lang.String size)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputsize
- size of the file- Returns:
- AbstractJob
-
uses
public AbstractJob uses(java.lang.String file, File.LINK link, File.TRANSFER transfer)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or not- Returns:
- AbstractJob
-
uses
public AbstractJob uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, java.lang.String size)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notsize
- size of the file- Returns:
- AbstractJob
-
uses
public AbstractJob uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, boolean register)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notregister
- whether to register the file or not- Returns:
- AbstractJob
-
uses
public AbstractJob uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, boolean register, boolean forPlanning)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notregister
- whether to register the file or notforPlanning
- whether the file is required for use by planner- Returns:
- AbstractJob
-
uses
public AbstractJob uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, boolean register, java.lang.String size)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notregister
- whether to register file or notsize
- size of the file- Returns:
- AbstractJob
-
uses
public AbstractJob uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, boolean register, boolean optional, boolean executable)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notregister
- whether to register the fileoptional
- whether file is optional or notexecutable
- whether file being transferred is an executable or not- Returns:
- AbstractJob
-
uses
public AbstractJob uses(java.lang.String file, File.LINK link, File.TRANSFER transfer, boolean register, boolean optional, boolean executable, java.lang.String size)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notregister
- whether to register the fileoptional
- whether file is optional or notexecutable
- whether file being transferred is an executable or notsize
- size- Returns:
- AbstractJob
-
uses
public AbstractJob uses(File file, File.LINK link)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or output- Returns:
- AbstractJob
-
uses
public AbstractJob uses(File file, File.LINK link, File.TRANSFER transfer)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or not- Returns:
- AbstractJob
-
uses
public AbstractJob uses(File file, File.LINK link, File.TRANSFER transfer, java.lang.String size)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notsize
- size of the file- Returns:
- AbstractJob
-
uses
public AbstractJob uses(File file, File.LINK link, boolean register)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputregister
- whether to register the file- Returns:
- AbstractJob
-
uses
public AbstractJob uses(File file, File.LINK link, boolean register, java.lang.String size)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputregister
- register flagsize
- size- Returns:
- AbstractJob
-
uses
public AbstractJob uses(File file, File.LINK link, java.lang.String size)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputsize
- size- Returns:
- AbstractJob
-
uses
public AbstractJob uses(File file, File.LINK link, File.TRANSFER transfer, boolean register)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notregister
- whether to register the file- Returns:
- AbstractJob
-
uses
public AbstractJob uses(File file, File.LINK link, File.TRANSFER transfer, boolean register, boolean forPlanning)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notregister
- whether to register the fileforPlanning
- whether the file is to be used for planning purposes- Returns:
- AbstractJob
-
uses
public AbstractJob uses(File file, File.LINK link, File.TRANSFER transfer, boolean register, java.lang.String size)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notregister
- whether to register the filesize
- size of the file- Returns:
- AbstractJob
-
uses
public AbstractJob uses(File file, File.LINK link, File.TRANSFER transfer, boolean register, boolean optional, boolean executable)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notregister
- whether to register the fileoptional
- whether file is optional or notexecutable
- whether file being transferred is an executable or not- Returns:
- AbstractJob
-
uses
public AbstractJob uses(File file, File.LINK link, File.TRANSFER transfer, boolean register, boolean optional, boolean executable, java.lang.String size)
- Parameters:
file
- the file used by the joblink
- indicating whether file is input or outputtransfer
- transfer flag indicating whether file should be transferred or notregister
- whether to register the fileoptional
- whether file is optional or notexecutable
- whether file being transferred is an executable or notsize
- size of the file- Returns:
- AbstractJob
-
uses
public AbstractJob uses(java.util.List<File> files, File.LINK link)
- Parameters:
files
- list of files to uselink
- linkage for the file- Returns:
- AbstractJob
-
getInvoke
public java.util.List<Invoke> getInvoke()
Returns list of Invoke objects- Returns:
- List of invoke objects
-
getNotification
public java.util.List<Invoke> getNotification()
Same as getInvoke(). Returns list of Invoke objects- Returns:
- List of invoke objects containing the notifications
-
addInvoke
public AbstractJob addInvoke(Invoke.WHEN when, java.lang.String what)
Add Notification to the job- Parameters:
when
- when to invokewhat
- what executable to invoke including the arguments- Returns:
- AbstractJob
-
addNotification
public AbstractJob addNotification(Invoke.WHEN when, java.lang.String what)
Add Notification to the job- Parameters:
when
- when to invokewhat
- what executable to invoke including the arguments- Returns:
- AbstractJob
-
addInvoke
public AbstractJob addInvoke(Invoke invoke)
Add notification to the job- Parameters:
invoke
- the Invoke object- Returns:
- AbstractJob
-
addNotification
public AbstractJob addNotification(Invoke invoke)
Add notification to the job- Parameters:
invoke
- the Invoke object- Returns:
- AbstractJob
-
addInvokes
public AbstractJob addInvokes(java.util.List<Invoke> invokes)
Add Notifications to the job- Parameters:
invokes
- list of invoke objects- Returns:
- AbstractJob
-
addNotifications
public AbstractJob addNotifications(java.util.List<Invoke> invokes)
Add Notifications to the job- Parameters:
invokes
- list of Invoke objects- Returns:
- AbstractJob
-
addMetaData
public AbstractJob addMetaData(java.lang.String key, java.lang.String value)
Adds metadata to the workflow- Parameters:
key
- key name for metadatavalue
- value- Returns:
- the Abstract Job
-
getMetaData
public java.lang.String getMetaData(java.lang.String key)
Returns the metadata associated for a key if exists, else null- Parameters:
key
- the metadata key- Returns:
- metadata key
-
isJob
public boolean isJob()
Is this Object a Job- Returns:
- boolean
-
isDAX
public boolean isDAX()
Is this Object a DAX- Returns:
- boolean
-
isDAG
public boolean isDAG()
Is this Object a DAG- Returns:
- boolean
-
getName
public java.lang.String getName()
- Returns:
- String
-
getId
public java.lang.String getId()
- Returns:
- String
-
getNodeLabel
public java.lang.String getNodeLabel()
- Returns:
- String
-
setNodeLabel
public void setNodeLabel(java.lang.String label)
- Parameters:
label
- node lable
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toXML
public void toXML(edu.isi.pegasus.common.util.XMLWriter writer)
- Parameters:
writer
- the XMLWriter
-
toXML
public void toXML(edu.isi.pegasus.common.util.XMLWriter writer, int indent)
- Parameters:
writer
- the XMLWriterindent
- indentation
-
-