public class CommandScript extends Object implements ExecutionScript
ExecutionScript.Kind, ExecutionScript.PlaceholderResolver| Modifier and Type | Field and Description |
|---|---|
static String |
DEFAULT_PROFILE_NAME
Default profile name (empty string).
|
ENV_ASAKUSA_HOME, PLACEHOLDER_ARGUMENTS, PLACEHOLDER_EXECUTION_ID, PLACEHOLDER_HOME| Constructor and Description |
|---|
CommandScript(String id,
Set<String> blockerIds,
String profileName,
String moduleName,
List<String> command,
Map<String,String> environmentVariables)
Creates a new instance.
|
CommandScript(String id,
Set<String> blockerIds,
String profileName,
String moduleName,
List<String> command,
Map<String,String> environmentVariables,
Collection<String> supportedExtensions)
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
Set<String> |
getBlockerIds()
Returns the IDs representing blockers of this script execution.
|
List<String> |
getCommandLineTokens()
Returns a sequence of command line tokens.
|
Map<String,String> |
getEnvironmentVariables()
Returns desired environment variables used in this execution.
|
String |
getId()
Returns the ID of this script execution.
|
ExecutionScript.Kind |
getKind()
Returns the kind of this script.
|
String |
getModuleName()
Returns a module name of target command.
|
String |
getProfileName()
Returns the profile name to execute this command.
|
Set<String> |
getSupportedExtensions()
Returns the supported extension names.
|
int |
hashCode() |
boolean |
isResolved()
Returns whether this script is resolved.
|
CommandScript |
resolve(ExecutionContext context,
ExecutionScriptHandler<?> handler)
Resolves placeholders defined in this script.
|
String |
toString() |
public static final String DEFAULT_PROFILE_NAME
public CommandScript(String id, Set<String> blockerIds, String profileName, String moduleName, List<String> command, Map<String,String> environmentVariables)
resolve(ExecutionContext, ExecutionScriptHandler).id - the script IDblockerIds - other script IDs blocking this script executionprofileName - the profile name to execute this command, empty string means use default profilemoduleName - module name of target commandcommand - sequence of command tokensenvironmentVariables - the extra environment variablesIllegalArgumentException - if some parameters were nullDEFAULT_PROFILE_NAME,
resolve(ExecutionContext, ExecutionScriptHandler)public CommandScript(String id, Set<String> blockerIds, String profileName, String moduleName, List<String> command, Map<String,String> environmentVariables, Collection<String> supportedExtensions)
resolve(ExecutionContext, ExecutionScriptHandler).id - the script IDblockerIds - other script IDs blocking this script executionprofileName - the profile name to execute this command, empty string means use default profilemoduleName - module name of target commandcommand - sequence of command tokensenvironmentVariables - the extra environment variablessupportedExtensions - the supported extension namesIllegalArgumentException - if some parameters were nullDEFAULT_PROFILE_NAME,
resolve(ExecutionContext, ExecutionScriptHandler)public ExecutionScript.Kind getKind()
ExecutionScriptgetKind in interface ExecutionScriptpublic String getId()
ExecutionScriptgetId in interface ExecutionScriptpublic Set<String> getBlockerIds()
ExecutionScriptgetBlockerIds in interface ExecutionScriptpublic String getProfileName()
DEFAULT_PROFILE_NAMEpublic String getModuleName()
public List<String> getCommandLineTokens()
public Map<String,String> getEnvironmentVariables()
ExecutionScriptgetEnvironmentVariables in interface ExecutionScriptpublic Set<String> getSupportedExtensions()
ExecutionScriptgetSupportedExtensions in interface ExecutionScriptpublic boolean isResolved()
ExecutionScriptisResolved in interface ExecutionScripttrue for resolved instance, otherwise falseExecutionScript.resolve(ExecutionContext, ExecutionScriptHandler)public CommandScript resolve(ExecutionContext context, ExecutionScriptHandler<?> handler) throws InterruptedException, IOException
ExecutionScriptresolve in interface ExecutionScriptcontext - current contexthandler - target handlerInterruptedException - if interrupted while resolving this objectIOException - if failed to resolve some entryExecutionScript.isResolved()Copyright © 2011–2018 Asakusa Framework Team. All rights reserved.