Examples of endObject()


Examples of com.ibm.commons.util.io.json.util.JsonWriter.endObject()

          } else {
            jw.outProperty(key, abstractedText);
          }
        }
      }
      jw.endObject();
      jw.flush();
    } catch (IOException e) {
      DominoUtils.handleException(e, this);
      return null;
    } catch (JsonException e) {
View Full Code Here

Examples of com.ibm.domino.services.util.JsonWriter.endObject()

              jsWriter.startProperty(strOGTag);
              jsWriter.outStringLiteral(urlFetcher.getOpenGraph()
                  .get(strOGTag));
              jsWriter.endProperty();
            }
            jsWriter.endObject();
          } else {
            jsWriter.outStringLiteral("");
          }
          jsWriter.endProperty();
          jsWriter.endObject();
View Full Code Here

Examples of com.oltpbenchmark.util.json.JSONStringer.endObject()

        JSONStringer stringer = new JSONStringer();
        try {
            if (object instanceof JSONSerializable) {
                stringer.object();
                ((JSONSerializable)object).toJSON(stringer);
                stringer.endObject();
            } else if (object != null) {
                Class<?> clazz = object.getClass();
//                stringer.key(clazz.getSimpleName());
                JSONUtil.writeFieldValue(stringer, clazz, object);
            }
View Full Code Here

Examples of com.orientechnologies.orient.core.serialization.serializer.OJSONWriter.endObject()

      } else

        throw new OSerializationException("Error on marshalling record of type '" + iRecord.getClass()
            + "' to JSON. The record type can't be exported to JSON");

      json.endObject(indentLevel);
      parsedRecords.clear();

      iOutput.append(buffer);
      return iOutput;
    } catch (IOException e) {
View Full Code Here

Examples of com.orientechnologies.orient.core.serialization.serializer.OJSONWriter.endObject()

          }
      }
    }
    json.endCollection(1, true);

    json.endObject();

    sendTextContent(iRequest, OHttpUtils.STATUS_OK_CODE, "OK", null, OHttpUtils.CONTENT_JSON, buffer.toString());
  }

  protected void sendRecordContent(final OHttpRequest iRequest, final ORecord<?> iRecord) throws IOException {
View Full Code Here

Examples of com.orientechnologies.orient.core.serialization.serializer.OJSONWriter.endObject()

          json.writeAttribute(3, false, "name", data.getName());
          json.writeAttribute(3, false, "size", data.getSize());
          json.writeAttribute(3, false, "filled", data.getFilledUpTo());
          json.writeAttribute(3, false, "maxSize", data.getConfig().maxSize);
          json.writeAttribute(3, false, "files", Arrays.toString(data.getConfig().infoFiles));
          json.endObject(2, false);
        }
        json.endCollection(1, true);
      }

      if (db.getClusterNames() != null) {
View Full Code Here

Examples of com.orientechnologies.orient.core.serialization.serializer.OJSONWriter.endObject()

              json.writeAttribute(3, false, "files", "-");
            }
          } catch (Exception e) {
            json.writeAttribute(3, false, "records", "? (Unauthorized)");
          }
          json.endObject(2, false);
        }
        json.endCollection(1, true);
      }

      if (db.getStorage() instanceof OStorageLocal) {
View Full Code Here

Examples of com.orientechnologies.orient.core.serialization.serializer.OJSONWriter.endObject()

        json.writeAttribute(3, false, "totalLogs", txSegment.getTotalLogCount());
        json.writeAttribute(3, false, "size", txSegment.getSize());
        json.writeAttribute(3, false, "filled", txSegment.getFilledUpTo());
        json.writeAttribute(3, false, "maxSize", txSegment.getConfig().maxSize);
        json.writeAttribute(3, false, "file", txSegment.getConfig().path);
        json.endObject(2, false);
        json.endCollection(1, true);
      }

      json.beginCollection(1, false, "users");
      OUser user;
View Full Code Here

Examples of com.orientechnologies.orient.core.serialization.serializer.OJSONWriter.endObject()

      for (ODocument doc : db.getMetadata().getSecurity().getUsers()) {
        user = new OUser(doc);
        json.beginObject(2, true, null);
        json.writeAttribute(3, false, "name", user.getName());
        json.writeAttribute(3, false, "roles", user.getRoles() != null ? Arrays.toString(user.getRoles().toArray()) : "null");
        json.endObject(2, false);
      }
      json.endCollection(1, true);

      json.beginCollection(1, true, "roles");
      ORole role;
View Full Code Here

Examples of com.orientechnologies.orient.core.serialization.serializer.OJSONWriter.endObject()

          json.writeAttribute(4, true, "name", rule.getKey());
          json.writeAttribute(4, false, "create", role.allow(rule.getKey(), ORole.PERMISSION_CREATE));
          json.writeAttribute(4, false, "read", role.allow(rule.getKey(), ORole.PERMISSION_READ));
          json.writeAttribute(4, false, "update", role.allow(rule.getKey(), ORole.PERMISSION_UPDATE));
          json.writeAttribute(4, false, "delete", role.allow(rule.getKey(), ORole.PERMISSION_DELETE));
          json.endObject(4, true);
        }
        json.endCollection(3, false);

        json.endObject(2, true);
      }
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.