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

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


      final OClass cls = db.getMetadata().getSchema().getClass(urlParts[2]);

      final OProperty prop = cls.createProperty(urlParts[3], OType.STRING);

      sendTextContent(iRequest, OHttpUtils.STATUS_CREATED_CODE, OHttpUtils.STATUS_CREATED_DESCRIPTION, null,
          OHttpUtils.CONTENT_TEXT_PLAIN, cls.properties().size());

    } finally {
      if (db != null)
        OSharedDocumentDatabase.release(db);
    }
View Full Code Here


        ++i;
      }
      out.println();
    }

    if (cls.properties().size() > 0) {
      out.println("Properties:");
      out.println("-------------------------------+-------------+-------------------------------+-----------+-----------+----------+------+------+");
      out.println(" NAME                          | TYPE        | LINKED TYPE/CLASS             | INDEX     | MANDATORY | NOT NULL | MIN  | MAX  |");
      out.println("-------------------------------+-------------+-------------------------------+-----------+-----------+----------+------+------+");
View Full Code Here

      out.println("Properties:");
      out.println("-------------------------------+-------------+-------------------------------+-----------+-----------+----------+------+------+");
      out.println(" NAME                          | TYPE        | LINKED TYPE/CLASS             | INDEX     | MANDATORY | NOT NULL | MIN  | MAX  |");
      out.println("-------------------------------+-------------+-------------------------------+-----------+-----------+----------+------+------+");

      for (OProperty p : cls.properties()) {
        try {
          out.printf(" %-30s| %-12s| %-30s| %-10s| %-10s| %-9s| %-5s| %-5s|\n", p.getName(), p.getType(),
              p.getLinkedClass() != null ? p.getLinkedClass() : p.getLinkedType(), p.getIndex() != null ? p.getIndex()
                  .getUnderlying().getType() : "", p.isMandatory(), p.isNotNull(), p.getMin() != null ? p.getMin() : "",
              p.getMax() != null ? p.getMax() : "");
View Full Code Here

        ++i;
      }
      out.println();
    }

    if (cls.properties().size() > 0) {
      out.println("Properties:");
      out.println("-------------------------------+----+-------------+-------------------------------+-----------+-----------+----------+------+------+");
      out.println(" NAME                          | ID | TYPE        | LINKED TYPE/CLASS             | INDEX     | MANDATORY | NOT NULL | MIN  | MAX  |");
      out.println("-------------------------------+----+-------------+-------------------------------+-----------+-----------+----------+------+------+");
View Full Code Here

      out.println("Properties:");
      out.println("-------------------------------+----+-------------+-------------------------------+-----------+-----------+----------+------+------+");
      out.println(" NAME                          | ID | TYPE        | LINKED TYPE/CLASS             | INDEX     | MANDATORY | NOT NULL | MIN  | MAX  |");
      out.println("-------------------------------+----+-------------+-------------------------------+-----------+-----------+----------+------+------+");

      for (OProperty p : cls.properties()) {
        try {
          out.printf(" %-30s|%3d | %-12s| %-30s| %-10s| %-10s| %-9s| %-5s| %-5s|\n", p.getName(), p.getId(), p.getType(),
              p.getLinkedClass() != null ? p.getLinkedClass() : p.getLinkedType(), p.getIndex() != null ? p.getIndex() : "",
              p.isMandatory(), p.isNotNull(), p.getMin() != null ? p.getMin() : "", p.getMax() != null ? p.getMax() : "");
        } catch (Exception e) {
View Full Code Here

    final OClass cls = iRecord.getSchemaClass();
    if (cls == null)
      return;

    OPropertyIndex index;
    for (OProperty prop : cls.properties()) {
      index = prop.getIndex();
      if (index != null)
        index.checkEntry(iRecord);
    }
  }
View Full Code Here

    OPropertyIndex index;
    Object fieldValue;

    Map<OProperty, Object> indexedProperties = null;

    for (OProperty prop : cls.properties()) {
      index = prop.getIndex();
      if (index != null) {
        if (prop.getType() == OType.LINK)
          // GET THE RID TO AVOID LOADING
          fieldValue = record.field(prop.getName(), OType.LINK);
View Full Code Here

        ++i;
      }
      out.println();
    }

    if (cls.properties().size() > 0) {
      out.println("Properties:");
      out.println("-------------------------------+----+-------------+-------------------------------+-----------+-----------+----------+------+------+");
      out.println(" NAME                          | ID | TYPE        | LINKED TYPE/CLASS             | INDEX     | MANDATORY | NOT NULL | MIN  | MAX  |");
      out.println("-------------------------------+----+-------------+-------------------------------+-----------+-----------+----------+------+------+");
View Full Code Here

      out.println("Properties:");
      out.println("-------------------------------+----+-------------+-------------------------------+-----------+-----------+----------+------+------+");
      out.println(" NAME                          | ID | TYPE        | LINKED TYPE/CLASS             | INDEX     | MANDATORY | NOT NULL | MIN  | MAX  |");
      out.println("-------------------------------+----+-------------+-------------------------------+-----------+-----------+----------+------+------+");

      for (OProperty p : cls.properties()) {
        try {
          out.printf(" %-30s|%3d | %-12s| %-30s| %-10s| %-10s| %-9s| %-5s| %-5s|\n", p.getName(), p.getId(), p.getType(),
              p.getLinkedClass() != null ? p.getLinkedClass() : p.getLinkedType(), p.getIndex() != null ? p.getIndex()
                  .getUnderlying().getType() : "", p.isMandatory(), p.isNotNull(), p.getMin() != null ? p.getMin() : "",
              p.getMax() != null ? p.getMax() : "");
View Full Code Here

        ++i;
      }
      out.println();
    }

    if (cls.properties().size() > 0) {
      out.println("Properties:");
      out.println("-------------------------------+----+-------------+-------------------------------+-----------+-----------+----------+------+------+");
      out.println(" NAME                          | ID | TYPE        | LINKED TYPE/CLASS             | INDEX     | MANDATORY | NOT NULL | MIN  | MAX  |");
      out.println("-------------------------------+----+-------------+-------------------------------+-----------+-----------+----------+------+------+");
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.