Class WriteJSONStep
java.lang.Object
hudson.model.AbstractDescribableImpl<org.jenkinsci.plugins.workflow.steps.Step>
org.jenkinsci.plugins.workflow.steps.Step
org.jenkinsci.plugins.pipeline.utility.steps.json.WriteJSONStep
- All Implemented Interfaces:
- ExtensionPoint,- Describable<org.jenkinsci.plugins.workflow.steps.Step>
public class WriteJSONStep
extends org.jenkinsci.plugins.workflow.steps.Step
Writes a 
JSON object to file in the current working directory.- Author:
- Nikolas Falco
- 
Nested Class SummaryNested ClassesNested classes/interfaces inherited from interface hudson.ExtensionPointExtensionPoint.LegacyInstancesAreScopedToHudson
- 
Constructor SummaryConstructorsConstructorDescriptionWriteJSONStep(Object json) WriteJSONStep(String file, Object json) Deprecated.
- 
Method SummaryModifier and TypeMethodDescriptiongetFile()Returns the name of the file to write.getJson()Return the JSON object to save.intReturn the number of spaces used to prettify the JSON dump.booleanvoidvoidsetReturnText(boolean returnText) org.jenkinsci.plugins.workflow.steps.StepExecutionstart(org.jenkinsci.plugins.workflow.steps.StepContext context) Methods inherited from class org.jenkinsci.plugins.workflow.steps.StepgetDescriptor
- 
Constructor Details- 
WriteJSONStep
- 
WriteJSONStepDeprecated.
 
- 
- 
Method Details- 
getFileReturns the name of the file to write.- Returns:
- the file name
 
- 
setFile
- 
getJsonReturn the JSON object to save.If it is not a JSONobject,JSONObject.fromObject(Object)will be used in a first step.- Returns:
- an object
 
- 
getPrettypublic int getPretty()Return the number of spaces used to prettify the JSON dump.- Returns:
- a int
 
- 
isReturnTextpublic boolean isReturnText()
- 
setReturnText@DataBoundSetter public void setReturnText(boolean returnText) 
- 
startpublic org.jenkinsci.plugins.workflow.steps.StepExecution start(org.jenkinsci.plugins.workflow.steps.StepContext context) throws Exception - Specified by:
- startin class- org.jenkinsci.plugins.workflow.steps.Step
- Throws:
- Exception
 
 
-