private void appendSingletons(final XMLStreamWriter writer, final List<EdmSingleton> singletons)
      throws XMLStreamException {
    for (EdmSingleton singleton : singletons) {
      writer.writeStartElement(XML_SINGLETON);
      writer.writeAttribute(XML_NAME, singleton.getName());
      writer.writeAttribute(
          XML_ENTITY_TYPE, getAliasedFullQualifiedName(singleton.getEntityType(), false));

      appendNavigationPropertyBindings(writer, singleton);
      writer.writeEndElement();
    }
  }
 private void writeSingletons(final JsonGenerator gen, final EdmEntityContainer container)
     throws IOException {
   for (EdmSingleton edmSingleton : container.getSingletons()) {
     writeElement(gen, SINGLETON, edmSingleton.getName(), edmSingleton.getName());
   }
 }
 @Override
 public String getSegmentValue() {
   return singleton.getName();
 }
 @Override
 public EdmEntityType getEntityType() {
   return singleton.getEntityType();
 }