Class JsonFileMacro
java.lang.Object
org.jenkinsci.plugins.tokenmacro.TokenMacro
org.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
org.jenkinsci.plugins.tokenmacro.WorkspaceDependentMacro
org.jenkinsci.plugins.tokenmacro.impl.JsonFileMacro
- All Implemented Interfaces:
ExtensionPoint
Expands to a xml value(s) from a xml file relative to the workspace root.
If xpath evaluates to more than one value then a semicolon separted string is returned.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
DataBoundTokenMacro.ParameterNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Field Summary
FieldsFields inherited from class org.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
escapeHtml -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanacceptsMacroName(String macroName) Returns true if this object can evaluate the macro of the given name.hudson.remoting.Callable<String,IOException> getCallable(Run<?, ?> run, String root, TaskListener listener) Methods inherited from class org.jenkinsci.plugins.tokenmacro.WorkspaceDependentMacro
evaluate, evaluateMethods inherited from class org.jenkinsci.plugins.tokenmacro.DataBoundTokenMacro
evaluate, evaluate, handlesHtmlEscapeInternally, hasNestedContentMethods inherited from class org.jenkinsci.plugins.tokenmacro.TokenMacro
all, expand, expand, expand, expand, expandAll, expandAll, expandAll, expandAll, getAutoCompleteList, getPreviousRun, getWorkspace
-
Field Details
-
LOGGER
-
file
-
path
-
expr
-
-
Constructor Details
-
JsonFileMacro
public JsonFileMacro()
-
-
Method Details
-
acceptsMacroName
Description copied from class:TokenMacroReturns true if this object can evaluate the macro of the given name.- Overrides:
acceptsMacroNamein classWorkspaceDependentMacro- Parameters:
macroName- By convention we encourage all caps name.- Returns:
- true
... to claim the macro of the given name and have
TokenMacro.evaluate(AbstractBuild, TaskListener, String, Map, ListMultimap)called.
-
getAcceptedMacroNames
- Overrides:
getAcceptedMacroNamesin classTokenMacro
-
getCallable
public hudson.remoting.Callable<String,IOException> getCallable(Run<?, ?> run, String root, TaskListener listener) - Specified by:
getCallablein classWorkspaceDependentMacro
-