public class ScriptDependency extends Object
ScriptingContext.isDependencyTracking()
to verify whether the script
is portable onto another environment, for example in form of an executable
package.T-Plan Robot Enterprise, (C) 2009-2025 T-Plan Limited. All rights reserved.
Constructor and Description |
---|
ScriptDependency()
Create a vanilla dependency.
|
ScriptDependency(ScriptingContext context)
Create a dependency and initialize its location (source script and line
number) from the argument context.
|
Modifier and Type | Method and Description |
---|---|
ScriptDependency |
forCurrentElement(ScriptingContext context)
Populate the dependency location (source script and line number) from the
argument context.
|
File |
getFile() |
ScriptLocation |
getLocation() |
String |
getName() |
String |
getPluginCode()
Get code of the plugin the script depends on.
|
boolean |
isConfigFile() |
boolean |
isCritical() |
boolean |
isLinux() |
boolean |
isMac() |
boolean |
isSystemSpecific() |
boolean |
isWindows() |
ScriptDependency |
makeCritical()
Indicate that the dependency is critical and must be strictly enforced.
|
ScriptDependency |
makeCurrentSystemSpecific()
Create dependency on the current OS.
|
ScriptDependency |
makeSystemSpecific()
Indicate that the dependency is system specific and enable the OS support
flags.
|
String |
toString() |
ScriptDependency |
withConfigFile()
Create dependency on the Robot configuration file.
|
ScriptDependency |
withFile(File f)
Create dependency on an external file or a file referenced with full
path.
|
ScriptDependency |
withLinux()
Indicate Linux support.
|
ScriptDependency |
withMac()
Indicate Mac OS support.
|
ScriptDependency |
withName(String name)
Set the dependency display name.
|
ScriptDependency |
withPlugin(String plugin)
Create dependency on an optional plugin.
|
ScriptDependency |
withWindows()
Indicate MS Windows support.
|
public ScriptDependency()
public ScriptDependency(ScriptingContext context)
context
- a script compilation context.public ScriptDependency forCurrentElement(ScriptingContext context)
context
- a script compilation context.public ScriptDependency withFile(File f)
f
- a file.public ScriptDependency withPlugin(String plugin)
plugin
- the plugin code.public ScriptDependency withName(String name)
name
- a name.public ScriptDependency withConfigFile()
public ScriptDependency makeCritical()
public ScriptDependency withMac()
makeSystemSpecific()
or
makeCurrentSystemSpecific()
is called too.public ScriptDependency withWindows()
makeSystemSpecific()
or
makeCurrentSystemSpecific()
is called too.public ScriptDependency withLinux()
makeSystemSpecific()
or
makeCurrentSystemSpecific()
is called too.public ScriptDependency makeSystemSpecific()
public ScriptDependency makeCurrentSystemSpecific()
public String getPluginCode()
public String getName()
public boolean isCritical()
public File getFile()
public boolean isMac()
public boolean isWindows()
public boolean isLinux()
public boolean isSystemSpecific()
public boolean isConfigFile()
public ScriptLocation getLocation()