WfdescWriter implements WorkflowBundleWriter { @Override public void writeBundle(WorkflowBundle wfBundle, File destination, String mediaType) throws WriterException, IOException { if (!mediaType.equals(TEXT_VND_WF4EVER_WFDESC_TURTLE)) { throw new WriterException("Unsupported media type: " + mediaType); } WfdescSerialiser serializer = new WfdescSerialiser(); BufferedOutputStream outStream = new BufferedOutputStream( new FileOutputStream(destination)); try { serializer.save(wfBundle, outStream); } finally { outStream.close(); } }  @Override Set<String> getMediaTypes(); @Override void writeBundle(WorkflowBundle wfBundle, File destination,
			String mediaType); @Override void writeBundle(WorkflowBundle wfBundle, OutputStream output,
			String mediaType);  }
@Test public void writeBundleToFile() throws Exception { File bundleFile = tempFile(); bundleIO.writeBundle(workflowBundle, bundleFile, TEXT_VND_WF4EVER_WFDESC_TURTLE); FileUtils.readFileToString(bundleFile, "utf-8"); }