public class PauseAction
extends hudson.model.InvisibleAction
implements org.jenkinsci.plugins.workflow.actions.PersistentAction
FlowNode
Action.
Simply marks the node as being a node that causes the build to pause e.g. an Input node.Constructor and Description |
---|
PauseAction(String cause) |
Modifier and Type | Method and Description |
---|---|
static void |
endCurrentPause(org.jenkinsci.plugins.workflow.graph.FlowNode node) |
String |
getCause() |
static PauseAction |
getCurrentPause(org.jenkinsci.plugins.workflow.graph.FlowNode node) |
long |
getEndTime() |
static List<PauseAction> |
getPauseActions(org.jenkinsci.plugins.workflow.graph.FlowNode node)
Get the
PauseAction instances for the supplied node. |
long |
getPauseDuration()
Get the pause duration for this flow node.
|
static long |
getPauseDuration(org.jenkinsci.plugins.workflow.graph.FlowNode node)
get the aggregate pause duration of the supplied flow node.
|
long |
getStartTime() |
boolean |
isPaused() |
static boolean |
isPaused(org.jenkinsci.plugins.workflow.graph.FlowNode node)
Simple helper method to test if the supplied node is a pause node.
|
void |
setCause(String cause) |
void |
setEndTime(long endTime) |
void |
setStartTime(long startTime) |
getDisplayName, getIconFileName, getUrlName
public PauseAction(String cause)
public String getCause()
public void setCause(String cause)
public long getStartTime()
public void setStartTime(long startTime)
public long getEndTime()
public void setEndTime(long endTime)
public boolean isPaused()
public long getPauseDuration()
@CheckForNull public static PauseAction getCurrentPause(@Nonnull org.jenkinsci.plugins.workflow.graph.FlowNode node)
public static void endCurrentPause(@Nonnull org.jenkinsci.plugins.workflow.graph.FlowNode node) throws IOException
IOException
public static boolean isPaused(@Nonnull org.jenkinsci.plugins.workflow.graph.FlowNode node)
node
- The node to test.@Nonnull public static List<PauseAction> getPauseActions(@Nonnull org.jenkinsci.plugins.workflow.graph.FlowNode node)
PauseAction
instances for the supplied node.node
- The node to be searched.PauseAction
instances for the supplied node. Returns an empty list if there are none.public static long getPauseDuration(@Nonnull org.jenkinsci.plugins.workflow.graph.FlowNode node)
node
- The node to calculate on.Copyright © 2016–2018. All rights reserved.