Package com.orientechnologies.orient.core.metadata.schema

Examples of com.orientechnologies.orient.core.metadata.schema.OClass.existsProperty()


  public void testCountFunctionWithNotUniqueIndex() {
    long oldIndexUsage = profiler.getCounter("db.demo.query.indexUsed");
    long oldcompositeIndexUsed = profiler.getCounter("db.demo.query.compositeIndexUsed");

    OClass klazz = database.getMetadata().getSchema().getOrCreateClass("CountFunctionWithNotUniqueHashIndex");
    if (!klazz.existsProperty("a")) {
      klazz.createProperty("a", OType.STRING);
      klazz.createIndex("CountFunctionWithNotUniqueHashIndex_A", "NOTUNIQUE_HASH_INDEX", "a");
    }

    ODocument doc = database.newInstance("CountFunctionWithNotUniqueHashIndex").field("a", "a").field("b", "b").save();
View Full Code Here


  public void testCountFunctionWithUniqueIndex() {
    long oldIndexUsage = profiler.getCounter("db.demo.query.indexUsed");
    long oldcompositeIndexUsed = profiler.getCounter("db.demo.query.compositeIndexUsed");

    OClass klazz = database.getMetadata().getSchema().getOrCreateClass("CountFunctionWithUniqueHashIndex");
    if (!klazz.existsProperty("a")) {
      klazz.createProperty("a", OType.STRING);
      klazz.createIndex("CountFunctionWithUniqueHashIndex_A", "UNIQUE_HASH_INDEX", "a");
    }

    ODocument doc = database.newInstance("CountFunctionWithUniqueHashIndex").field("a", "a").field("b", "b").save();
View Full Code Here

      if (!warn && !edgeBaseClass.getName().equals(OrientEdgeType.CLASS_NAME)) {
        OLogManager.instance().warn(null, "Found Edge class %s" + MSG_SUFFIX, edgeBaseClass.getName());
        warn = true;
      }

      if (edgeBaseClass.existsProperty(CONNECTION_OUT) || edgeBaseClass.existsProperty(CONNECTION_IN)) {
        OLogManager.instance().warn(null, "Found property in/out against E");
        warn = true;
      }
    }
  }
View Full Code Here

      if (!warn && !edgeBaseClass.getName().equals(OrientEdgeType.CLASS_NAME)) {
        OLogManager.instance().warn(null, "Found Edge class %s" + MSG_SUFFIX, edgeBaseClass.getName());
        warn = true;
      }

      if (edgeBaseClass.existsProperty(CONNECTION_OUT) || edgeBaseClass.existsProperty(CONNECTION_IN)) {
        OLogManager.instance().warn(null, "Found property in/out against E");
        warn = true;
      }
    }
  }
View Full Code Here

            "Found Edge class %s" + MSG_SUFFIX,
            edgeBaseClass.getName());
        warn = true;
      }

      if (edgeBaseClass.existsProperty(CONNECTION_OUT)
          || edgeBaseClass.existsProperty(CONNECTION_IN)) {
        OLogManager.instance().warn(this,
            "Found property in/out against E");
        warn = true;
      }
View Full Code Here

            edgeBaseClass.getName());
        warn = true;
      }

      if (edgeBaseClass.existsProperty(CONNECTION_OUT)
          || edgeBaseClass.existsProperty(CONNECTION_IN)) {
        OLogManager.instance().warn(this,
            "Found property in/out against E");
        warn = 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.