@Test public void testWriteODataMetadataFeed() throws Exception { startDocument(true); metadataWriter = new AtomMetadataWriter(xmlWriter, odataUri, entityDataModel, nsConfigurationProvider); metadataWriter.writeODataMetadata(CUSTOMERS_URL); endDocument(); assertEquals(prettyPrintXml(readContent(EXPECTED_FEED_METADATA_PATH)), prettyPrintXml(outputStream.toString())); }
void writeODataMetadata(String contextURL) throws XMLStreamException { xmlWriter.writeNamespace(METADATA, nsConfigurationProvider.getOdataMetadataNs()); xmlWriter.writeNamespace(ODATA_DATA, nsConfigurationProvider.getOdataDataNs()); xmlWriter.writeDefaultNamespace(ATOM_NS); xmlWriter.writeAttribute(nsConfigurationProvider.getOdataMetadataNs(), ODATA_CONTEXT, contextURL); xmlWriter.writeAttribute(ODATA_XML_BASE, oDataUri.serviceRoot()); }
AtomMetadataWriter { void writeODataMetadata(String contextURL) throws XMLStreamException { xmlWriter.writeNamespace(METADATA, nsConfigurationProvider.getOdataMetadataNs()); xmlWriter.writeNamespace(ODATA_DATA, nsConfigurationProvider.getOdataDataNs()); xmlWriter.writeDefaultNamespace(ATOM_NS); xmlWriter.writeAttribute(nsConfigurationProvider.getOdataMetadataNs(), ODATA_CONTEXT, contextURL); xmlWriter.writeAttribute(ODATA_XML_BASE, oDataUri.serviceRoot()); } }
AtomMetadataWriter { void writeODataMetadata(String contextURL) throws XMLStreamException { xmlWriter.writeNamespace(METADATA, nsConfigurationProvider.getOdataMetadataNs()); xmlWriter.writeNamespace(ODATA_DATA, nsConfigurationProvider.getOdataDataNs()); xmlWriter.writeDefaultNamespace(ATOM_NS); xmlWriter.writeAttribute(nsConfigurationProvider.getOdataMetadataNs(), ODATA_CONTEXT, contextURL); xmlWriter.writeAttribute(ODATA_XML_BASE, oDataUri.serviceRoot()); } AtomMetadataWriter(XMLStreamWriter xmlWriter, ODataUri oDataUri,
                              EntityDataModel entityDataModel, AtomNSConfigurationProvider nsConfigurationProvider); }
AtomMetadataWriter { void writeODataMetadata(String contextURL) throws XMLStreamException { xmlWriter.writeNamespace(METADATA, nsConfigurationProvider.getOdataMetadataNs()); xmlWriter.writeNamespace(ODATA_DATA, nsConfigurationProvider.getOdataDataNs()); xmlWriter.writeDefaultNamespace(ATOM_NS); xmlWriter.writeAttribute(nsConfigurationProvider.getOdataMetadataNs(), ODATA_CONTEXT, contextURL); xmlWriter.writeAttribute(ODATA_XML_BASE, oDataUri.serviceRoot()); } AtomMetadataWriter(XMLStreamWriter xmlWriter, ODataUri oDataUri,
                              EntityDataModel entityDataModel, AtomNSConfigurationProvider nsConfigurationProvider); void writeEntryEntityLink(Object entity); void writeCount(Object count); }
AtomMetadataWriter { void writeODataMetadata(String contextURL) throws XMLStreamException { xmlWriter.writeNamespace(METADATA, nsConfigurationProvider.getOdataMetadataNs()); xmlWriter.writeNamespace(ODATA_DATA, nsConfigurationProvider.getOdataDataNs()); xmlWriter.writeDefaultNamespace(ATOM_NS); xmlWriter.writeAttribute(nsConfigurationProvider.getOdataMetadataNs(), ODATA_CONTEXT, contextURL); xmlWriter.writeAttribute(ODATA_XML_BASE, oDataUri.serviceRoot()); } AtomMetadataWriter(XMLStreamWriter xmlWriter, ODataUri oDataUri,
                              EntityDataModel entityDataModel, AtomNSConfigurationProvider nsConfigurationProvider); void writeEntryEntityLink(Object entity); void writeCount(Object count);  }