Package jenkins.tasks
Class SimpleBuildWrapper.Context
- java.lang.Object
-
- jenkins.tasks.SimpleBuildWrapper.Context
-
- Enclosing class:
- SimpleBuildWrapper
public static final class SimpleBuildWrapper.Context extends Object
Parameter passed toSimpleBuildWrapper.setUp(jenkins.tasks.SimpleBuildWrapper.Context, hudson.model.Run<?, ?>, hudson.FilePath, hudson.Launcher, hudson.model.TaskListener, hudson.EnvVars)to allow an implementation to specify its behavior after the initial setup.
-
-
Constructor Summary
Constructors Constructor Description Context()Deprecated.UseSimpleBuildWrapper.createContext()instead, so that this context can tell whether or not a disposer will require a workspace context.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidenv(String key, String value)Specify an environment variable override to apply to processes launched within the block.SimpleBuildWrapper.DisposergetDisposer()Map<String,String>getEnv()voidsetDisposer(SimpleBuildWrapper.Disposer disposer)Specify an action to take when the block ends.
-
-
-
Constructor Detail
-
Context
@Deprecated public Context()
Deprecated.UseSimpleBuildWrapper.createContext()instead, so that this context can tell whether or not a disposer will require a workspace context.Creates a new context.
-
-
Method Detail
-
env
public void env(String key, String value)
Specify an environment variable override to apply to processes launched within the block. If unspecified, environment variables will be inherited unmodified.- Parameters:
key- handles the specialPATH+SOMETHINGsyntax as inEnvVars.override(java.lang.String, java.lang.String)
-
getDisposer
@CheckForNull public SimpleBuildWrapper.Disposer getDisposer()
-
setDisposer
public void setDisposer(@NonNull SimpleBuildWrapper.Disposer disposer)Specify an action to take when the block ends. If not specified, nothing special happens.
-
-