Package org.apache.olingo.odata2.core.ep.util

Examples of org.apache.olingo.odata2.core.ep.util.JsonStreamWriter.separator()


      boolean first = true;
      for (final Object order : orders) {
        if (first) {
          first = false;
        } else {
          jsonStreamWriter.separator();
        }
        jsonStreamWriter.unquotedValue(order.toString());
      }
      jsonStreamWriter.endArray().endObject();
      writer.flush();
View Full Code Here


      boolean first = true;
      for (Object parameter : parameters) {
        if (first) {
          first = false;
        } else {
          jsonStreamWriter.separator();
        }
        jsonStreamWriter.unquotedValue(parameter.toString());
      }
      jsonStreamWriter.endArray().endObject();
      writer.flush();
View Full Code Here

      boolean first = true;
      for (final Map<String, Object> entryData : data) {
        if (first) {
          first = false;
        } else {
          jsonStreamWriter.separator();
        }
        entryProducer.append(writer, entityInfo, entryData, false);
      }

      if (callback != null) {
View Full Code Here

      boolean first = true;
      for (EdmProperty property : properties) {
        if (first) {
          first = false;
        } else {
          jsonStreamWriter.separator();
        }
        jsonStreamWriter.stringValueRaw(property.getName());
      }
      jsonStreamWriter.endArray().separator()
          .name("links")
View Full Code Here

      first = true;
      for (Map.Entry<String, ExpandSelectTreeNodeImpl> entry : links.entrySet()) {
        if (first) {
          first = false;
        } else {
          jsonStreamWriter.separator();
        }
        final String nodeString = entry.getValue() == null ? null : entry.getValue().toJsonString();
        jsonStreamWriter.beginObject()
            .name(entry.getKey()).unquotedValue(nodeString)
            .endObject();
View Full Code Here

    BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(csb.getOutputStream(), "UTF-8"));
    JsonStreamWriter jsonStreamWriter = new JsonStreamWriter(writer);
    jsonStreamWriter.beginObject();
    jsonStreamWriter.name(parts.get(0).getName().toLowerCase(Locale.ROOT));
    parts.get(0).appendJson(jsonStreamWriter);
    jsonStreamWriter.separator();
    jsonStreamWriter.name(parts.get(1).getName().toLowerCase(Locale.ROOT));
    parts.get(1).appendJson(jsonStreamWriter);
    if (parts.size() > 2) {
      jsonStreamWriter.separator();
      jsonStreamWriter.name("server")
View Full Code Here

    parts.get(0).appendJson(jsonStreamWriter);
    jsonStreamWriter.separator();
    jsonStreamWriter.name(parts.get(1).getName().toLowerCase(Locale.ROOT));
    parts.get(1).appendJson(jsonStreamWriter);
    if (parts.size() > 2) {
      jsonStreamWriter.separator();
      jsonStreamWriter.name("server")
          .beginObject();
    }
    boolean first = true;
    for (final DebugInfo part : parts.subList(2, parts.size())) {
View Full Code Here

          .beginObject();
    }
    boolean first = true;
    for (final DebugInfo part : parts.subList(2, parts.size())) {
      if (!first) {
        jsonStreamWriter.separator();
      }
      first = false;
      jsonStreamWriter.name(part.getName().toLowerCase(Locale.ROOT));
      part.appendJson(jsonStreamWriter);
    }
View Full Code Here

      boolean first = true;
      for (EdmProperty property : properties) {
        if (first) {
          first = false;
        } else {
          jsonStreamWriter.separator();
        }
        jsonStreamWriter.stringValueRaw(property.getName());
      }
      jsonStreamWriter.endArray().separator()
          .name("links")
View Full Code Here

      first = true;
      for (Map.Entry<String, ExpandSelectTreeNodeImpl> entry : links.entrySet()) {
        if (first) {
          first = false;
        } else {
          jsonStreamWriter.separator();
        }
        final String nodeString = entry.getValue() == null ? null : entry.getValue().toJsonString();
        jsonStreamWriter.beginObject()
            .name(entry.getKey()).unquotedValue(nodeString)
            .endObject();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.