Package com.orientechnologies.orient.core.serialization.serializer

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


             "name", "localeCountry", "value", db.getStorage().getConfiguration().getLocaleCountry() }, new Object[] { "name",
             "localeLanguage", "value", db.getStorage().getConfiguration().getLocaleLanguage() }, new Object[] { "name",
             "definitionVersion", "value", db.getStorage().getConfiguration().version });
     json.endCollection(2, true);

     json.beginCollection(2, true, "properties");
     if (db.getStorage().getConfiguration().properties != null)
       for (OStorageEntryConfiguration entry : db.getStorage().getConfiguration().properties) {
         if (entry != null) {
           json.beginObject(3, true, null);
           json.writeAttribute(4, false, "name", entry.name);
View Full Code Here


       json.writeAttribute("javaVendor", System.getProperty("java.vm.vendor"));
       json.writeAttribute("javaVersion", System.getProperty("java.vm.version"));
       json.endObject();

       if (db.getMetadata().getSchema().getClasses() != null) {
         json.beginCollection("classes");
         List<String> classNames = new ArrayList<String>();

         for (OClass cls : db.getMetadata().getSchema().getClasses())
           classNames.add(cls.getName());
         Collections.sort(classNames);
View Full Code Here

         }
         json.endCollection();
       }

       if (db.getClusterNames() != null) {
         json.beginCollection("clusters");
         OCluster cluster;
         for (String clusterName : db.getClusterNames()) {
           try {
             cluster = db.getStorage().getClusterById(db.getClusterIdByName(clusterName));
           } catch (IllegalArgumentException e) {
View Full Code Here

       }

       if (db.getUser() != null) {
         json.writeAttribute("currentUser", db.getUser().getName());

         json.beginCollection("users");
//        for (ODocument doc : db.getMetadata().getSecurity().getAllUsers()) {
//          OUser user = new OUser(doc);
//          json.beginObject();
//          json.writeAttribute("name", user.getName());
//          json.writeAttribute("roles", user.getRoles() != null ? Arrays.toString(user.getRoles().toArray()) : "null");
View Full Code Here

//          json.writeAttribute("roles", user.getRoles() != null ? Arrays.toString(user.getRoles().toArray()) : "null");
//          json.endObject();
//        }
         json.endCollection();

         json.beginCollection("roles");
//        ORole role;
//        for (ODocument doc : db.getMetadata().getSecurity().getAllRoles()) {
//          role = new ORole(doc);
//          json.beginObject();
//          json.writeAttribute("name", role.getName());
View Full Code Here

//        }
         json.endCollection();
       }

       final OIndexManagerProxy idxManager = db.getMetadata().getIndexManager();
       json.beginCollection("indexes");
       for (OIndex<?> index : idxManager.getIndexes()) {
         json.beginObject();
         try {
           json.writeAttribute("name", index.getName());
           json.writeAttribute("configuration", index.getConfiguration());
View Full Code Here

       }
       json.endCollection();

       json.beginObject("config");

       json.beginCollection("values");
       json.writeObjects(null, new Object[] { "name", "dateFormat", "value", db.getStorage().getConfiguration().dateFormat },
           new Object[] { "name", "dateTimeFormat", "value", db.getStorage().getConfiguration().dateTimeFormat }, new Object[] {
               "name", "localeCountry", "value", db.getStorage().getConfiguration().getLocaleCountry() }, new Object[] { "name",
               "localeLanguage", "value", db.getStorage().getConfiguration().getLocaleLanguage() }, new Object[] { "name",
               "charSet", "value", db.getStorage().getConfiguration().getCharset() }, new Object[] { "name", "timezone", "value",
View Full Code Here

               db.getStorage().getConfiguration().getClusterSelection() }, new Object[] { "name", "minimumClusters", "value",
               db.getStorage().getConfiguration().getMinimumClusters() }, new Object[] { "name", "conflictStrategy", "value",
                                                                                        db.getStorage().getConfiguration().getConflictStrategy() });
       json.endCollection();

       json.beginCollection("properties");
       if (db.getStorage().getConfiguration().properties != null)
         for (OStorageEntryConfiguration entry : db.getStorage().getConfiguration().properties) {
           if (entry != null) {
             json.beginObject();
             json.writeAttribute("name", entry.name);
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.