Package com.orientechnologies.orient.core.db.document

Examples of com.orientechnologies.orient.core.db.document.ODatabaseDocument.create()


          db = new ODatabaseDocumentTx(stg.path);

          if (db.exists())
            db.open(stg.userName, stg.userPassword);
          else
            db.create();

          OLogManager.instance().info(this, "-> Loaded " + type + " database '" + stg.name + "'");
        } catch (Exception e) {
          OLogManager.instance().error(this, "-> Can't load " + type + " database '" + stg.name + "': " + e);
View Full Code Here


          db = new ODatabaseDocumentTx(stg.path);

          if (db.exists())
            db.open(stg.userName, stg.userPassword);
          else
            db.create();

          OLogManager.instance().info(this, "-> Loaded " + type + " database '" + stg.name + "'");
        } catch (Exception e) {
          OLogManager.instance().error(this, "-> Can't load " + type + " database '" + stg.name + "': " + e);
View Full Code Here

          db = new ODatabaseDocumentTx(stg.path);

          if (db.exists())
            db.open(stg.userName, stg.userPassword);
          else
            db.create();

          OLogManager.instance().info(this, "-> Loaded " + type + " database '" + stg.name + "'");
        } catch (Exception e) {
          OLogManager.instance().error(this, "-> Can't load " + type + " database '" + stg.name + "': " + e);
View Full Code Here

          db = new ODatabaseDocumentTx(stg.path);

          if (db.exists())
            db.open(stg.userName, stg.userPassword);
          else
            db.create();

          OLogManager.instance().info(this, "-> Loaded " + type + " database '" + stg.name + "'");
        } catch (Exception e) {
          OLogManager.instance().error(this, "-> Can't load " + type + " database '" + stg.name + "': " + e);
View Full Code Here

          db = new ODatabaseDocumentTx(stg.path);

          if (db.exists())
            db.open(stg.userName, stg.userPassword);
          else {
            db.create();
            if (stg.userName.equals(OUser.ADMIN)) {
              if (!stg.userPassword.equals(OUser.ADMIN))
                // CHANGE ADMIN PASSWORD
                db.getMetadata().getSecurity().getUser(OUser.ADMIN).setPassword(stg.userPassword);
            } else {
View Full Code Here

    if (prefix.equals("memory:") || prefix.equals("remote:"))
      return;

    ODatabaseDocument db = new ODatabaseDocumentTx(prefix + testPath + "/" + DbImportExportTest.NEW_DB_URL);
    if (!db.exists())
      db.create();

    if (db.exists()) {
      if (db.isClosed())
        db.open("admin", "admin");
    }
View Full Code Here

    if (prefix.equals("remote:"))
      return;

    ODatabaseDocument db = new ODatabaseDocumentTx(prefix + testPath + "/" + DbImportExportTest.NEW_DB_URL);
    if (!db.exists())
      db.create();

    if (db.exists()) {
      if (db.isClosed())
        db.open("admin", "admin");
View Full Code Here

    if (db.exists()) {
      if (db.isClosed())
        db.open("admin", "admin");

      db.drop();
      db.create();
    }

    final OClass indexedClass = db.getMetadata().getSchema().createClass("IndexedClass");
    indexedClass.createProperty("value", OType.STRING);
    indexedClass.createIndex("indexValue", OClass.INDEX_TYPE.UNIQUE, "value");
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.