Class Token
java.lang.Object
org.jenkinsci.plugins.tokenmacro.TokenMacro
org.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
com.sonyericsson.jenkins.plugins.bfa.tokens.Token
- All Implemented Interfaces:
ExtensionPoint
@Extension(optional=true)
public class Token
extends org.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
The Build Failure Analyzer token for TokenMacro consumers.
- Author:
- K. R. Walker <krwalker@stellarscience.com>
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
org.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro.Parameter
Nested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson
-
Field Summary
Fields inherited from class org.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
escapeHtml
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
acceptsMacroName
(String macroName) evaluate
(AbstractBuild<?, ?> build, TaskListener listener, String macroName) evaluate
(Run<?, ?> run, FilePath workspace, TaskListener listener, String macroName) boolean
void
setIncludeIndications
(boolean includeIndications) void
setIncludeTitle
(boolean includeTitle) void
setNoFailureText
(String noFailureText) void
setUseHtmlFormat
(boolean useHtmlFormat) void
setWrapWidth
(int wrapWidth) Methods inherited from class org.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
evaluate, evaluate, hasNestedContent
Methods inherited from class org.jenkinsci.plugins.tokenmacro.TokenMacro
all, expand, expand, expand, expand, expandAll, expandAll, expandAll, expandAll, getAcceptedMacroNames, getAutoCompleteList, getPreviousRun, getWorkspace
-
Constructor Details
-
Token
public Token()
-
-
Method Details
-
setIncludeIndications
public void setIncludeIndications(boolean includeIndications) - Parameters:
includeIndications
- When true, the indication numbers and links into the console log are included in the token replacement text.
-
setUseHtmlFormat
public void setUseHtmlFormat(boolean useHtmlFormat) - Parameters:
useHtmlFormat
- When true, the replacement text will be an HTML snippet.
-
setIncludeTitle
public void setIncludeTitle(boolean includeTitle) - Parameters:
includeTitle
- When true, the title will appear in the token replacement text.
-
setWrapWidth
public void setWrapWidth(int wrapWidth) - Parameters:
wrapWidth
- Wrap long lines at this width. If wrapWidth is 0, the text isn't wrapped. Only applies if useHtmlFormat == false.
-
setNoFailureText
- Parameters:
noFailureText
- Text to return when no failure cause is present.
-
acceptsMacroName
- Specified by:
acceptsMacroName
in classorg.jenkinsci.plugins.tokenmacro.TokenMacro
-
handlesHtmlEscapeInternally
public boolean handlesHtmlEscapeInternally()- Overrides:
handlesHtmlEscapeInternally
in classorg.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
-
evaluate
public String evaluate(AbstractBuild<?, ?> build, TaskListener listener, String macroName) throws org.jenkinsci.plugins.tokenmacro.MacroEvaluationException, IOException, InterruptedException- Specified by:
evaluate
in classorg.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
- Throws:
org.jenkinsci.plugins.tokenmacro.MacroEvaluationException
IOException
InterruptedException
-
evaluate
public String evaluate(Run<?, ?> run, FilePath workspace, TaskListener listener, String macroName) throws org.jenkinsci.plugins.tokenmacro.MacroEvaluationException, IOException, InterruptedException- Overrides:
evaluate
in classorg.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
- Throws:
org.jenkinsci.plugins.tokenmacro.MacroEvaluationException
IOException
InterruptedException
-