public class JsonExport.JsonWriter extends Object implements WorkflowBundleWriter
Constructor and Description |
---|
JsonWriter() |
Modifier and Type | Method and Description |
---|---|
Set<String> |
getMediaTypes()
Returns the media types that this writer can handle.
|
void |
writeBundle(WorkflowBundle wfBundle,
File destination,
String mediaType)
Writes a
WorkflowBundle to a file with specified media type. |
void |
writeBundle(WorkflowBundle wfBundle,
OutputStream output,
String mediaType)
Writes a
WorkflowBundle to a stream with specified media
type. |
public Set<String> getMediaTypes()
WorkflowBundleWriter
getMediaTypes
in interface WorkflowBundleWriter
public void writeBundle(WorkflowBundle wfBundle, File destination, String mediaType) throws WriterException, IOException
WorkflowBundleWriter
WorkflowBundle
to a file with specified media type.writeBundle
in interface WorkflowBundleWriter
wfBundle
- the workflow bundle to writedestination
- the file to write the workflow bundle tomediaType
- the media type to write workflow bundle inWriterException
- if there is an error writing the workflow bundleIOException
- if there is an error writing the filepublic void writeBundle(WorkflowBundle wfBundle, OutputStream output, String mediaType) throws WriterException, IOException
WorkflowBundleWriter
WorkflowBundle
to a stream with specified media
type.writeBundle
in interface WorkflowBundleWriter
wfBundle
- the workflow bundle to writeoutput
- the stream to write the workflow bundle tomediaType
- the media type to write workflow bundle inWriterException
- if there is an error writing the workflow bundleIOException
- if there is an error writing to the streamCopyright © 2015–2016 The Apache Software Foundation. All rights reserved.