PseudoRdfXmlWriter extends AbstractXmlWriter { public void write(OutputStream stream, OWLGraphWrapper graph, List<GafDocument> gafs) throws IOException { try { XMLStreamWriter writer = createWriter(stream); writer.writeStartDocument(); writer.writeDTD("\n<!DOCTYPE go:go PUBLIC \"- writer.writeStartElement("go:go"); writer.writeNamespace("go", GO_NAMESPACE_URI); writer.writeNamespace("rdf", RDF_NAMESPACE_URI); writer.writeStartElement(RDF_NAMESPACE_URI, "RDF"); writeTerms(writer, graph, gafs); writer.writeEndElement(); writer.writeEndElement(); writer.writeEndDocument(); writer.flush(); } catch (XMLStreamException e) { throw new IOException(e); } } PseudoRdfXmlWriter(); void setProgressReporter(ProgressReporter reporter); void write(OutputStream stream, OWLGraphWrapper graph, List<GafDocument> gafs);  }
@Ignore @Test public void testWriter() throws Exception { GafObjectsBuilder builder = new GafObjectsBuilder(); GafDocument gaf = builder.buildDocument(getResource("test_gene_association_mgi.gaf")); PseudoRdfXmlWriter w = new PseudoRdfXmlWriter(); w.write(System.out, graph, Arrays.asList(gaf)); }