Examples of endCollection()


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

        json.beginObject(3);
        writeField(json, 3, "name", c);
        writeField(json, 3, "value", OProfiler.getInstance().getCounter(c));
        json.endObject(3);
      }
      json.endCollection(2, false);

      OProfilerEntry pEntry;

      json.beginCollection(2, true, "stats");
      for (String s : OProfiler.getInstance().getStats()) {
View Full Code Here

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

        writeField(json, 3, "maxElapsed", pEntry.max);
        writeField(json, 3, "lastElapsed", pEntry.last);
        writeField(json, 3, "totalElapsed", pEntry.total);
        json.endObject(3);
      }
      json.endCollection(2, false);

      json.beginCollection(2, true, "chronos");
      for (String c : OProfiler.getInstance().getChronos()) {
        pEntry = OProfiler.getInstance().getChrono(c);
View Full Code Here

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

        writeField(json, 3, "maxElapsed", pEntry.max);
        writeField(json, 3, "lastElapsed", pEntry.last);
        writeField(json, 3, "totalElapsed", pEntry.total);
        json.endObject(3);
      }
      json.endCollection(2, false);
      json.endObject(1);

      json.endObject();

      sendTextContent(iRequest, OHttpUtils.STATUS_OK_CODE, "OK", null, OHttpUtils.CONTENT_JSON, jsonBuffer.toString());
View Full Code Here

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

            exportClass(db, json, cls);
          } catch (Exception e) {
            OLogManager.instance().error(this, "Error on exporting class '" + cls + "'", e);
          }
        }
        json.endCollection(1, true);
      }

      if (db.getStorage() instanceof OStorageLocal) {
        json.beginCollection(1, false, "dataSegments");
        for (ODataLocal data : ((OStorageLocal) db.getStorage()).getDataSegments()) {
View Full Code Here

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

          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) {
        json.beginCollection(1, false, "clusters");
        OCluster cluster;
View Full Code Here

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

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

      if (db.getStorage() instanceof OStorageLocal) {
        json.beginCollection(1, false, "txSegment");
        final OTxSegment txSegment = ((OStorageLocal) db.getStorage()).getTxManager().getTxSegment();
View Full Code Here

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

        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;
      for (ODocument doc : db.getMetadata().getSecurity().getUsers()) {
View Full Code Here

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

          } catch (Exception e) {
            OLogManager.instance().error(this, "Error transforming record " + rec.getIdentity() + " to JSON", e);
          }
      }
    }
    json.endCollection(1, true);

    json.endObject();

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

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

          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);
      }
      json.endCollection(1, true);
View Full Code Here

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

        }
        json.endCollection(3, false);

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

      json.beginObject(1, true, "config");

      json.beginCollection(2, true, "values");
      json.writeObjects(3, true, null,
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.