Package com.orientechnologies.orient.core.record

Examples of com.orientechnologies.orient.core.record.ORecord.save()


      OIdentifiable identifiable = entry.getKey();
      if (identifiable instanceof ORecord) {
        ORID identity = identifiable.getIdentity();
        ORecord record = (ORecord) identifiable;
        if (identity.isNew() || record.isDirty()) {
          record.save();
          identity = record.getIdentity();
        }

        newChangedValues.put(identity, entry.getValue());
      } else
View Full Code Here


    }

    for (Map.Entry<OIdentifiable, Change> entry : newChangedValues.entrySet()) {
      if (entry.getKey() instanceof ORecord) {
        ORecord record = (ORecord) entry.getKey();
        record.save();

        newChangedValues.put(record, entry.getValue());
      } else
        return false;
    }
View Full Code Here

    for (OIdentifiable identifiable : changes.keySet()) {
      if (identifiable instanceof ORecord) {
        final ORID identity = identifiable.getIdentity();
        final ORecord record = (ORecord) identifiable;
        if (identity.isNew() || record.isDirty()) {
          record.save();
        }
      }
    }

    for (Map.Entry<OIdentifiable, OModifiableInteger> entry : newEntries.entrySet()) {
View Full Code Here

      if (entry instanceof OIdentifiable) {
        final OIdentifiable identifiable = (OIdentifiable) entry;
        if (identifiable instanceof ORecord) {
          final ORecord record = (ORecord) identifiable;
          if (record.getIdentity().isNew()) {
            record.save();
          }

          entries[i] = record.getIdentity();
        }
      }
View Full Code Here

      if (entry instanceof OIdentifiable) {
        final OIdentifiable identifiable = (OIdentifiable) entry;
        if (identifiable instanceof ORecord) {
          final ORecord record = (ORecord) identifiable;
          if (record.isDirty() || record.getIdentity().isNew()) {
            record.save();
          }
        }
      }
    }
View Full Code Here

          boolean first = true;
          for (OIdentifiable rid : tree.keySet()) {
            if (rid instanceof ORecord) {
              final ORecord record = (ORecord) rid;
              if (record.isDirty())
                record.save();
            }

            if (!first)
              buffer.append(OStringSerializerHelper.COLLECTION_SEPARATOR);
            else
View Full Code Here

         final ORecord record = iCurrentRID.getRecord();
         ORecordInternal.setVersion(record, iOtherVersion - 1);
         record.setDirty();

         try {
           record.save();
           return;
         } catch (OConcurrentModificationException e) {
           // CONCURRENT OPERATION, RETRY AGAIN?
         }
       }
View Full Code Here

    if (key instanceof ORecord) {
      // RECORD KEY: ASSURE IT'S PERSISTENT TO AVOID STORING INVALID RIDs
      rec = (ORecord) key;
      if (!rec.getIdentity().isValid())
        rec.save();
    }

    if (value instanceof ORecord) {
      // RECORD VALUE: ASSURE IT'S PERSISTENT TO AVOID STORING INVALID RIDs
      rec = (ORecord) value;
View Full Code Here

    if (value instanceof ORecord) {
      // RECORD VALUE: ASSURE IT'S PERSISTENT TO AVOID STORING INVALID RIDs
      rec = (ORecord) value;
      if (!rec.getIdentity().isValid())
        rec.save();
    }

    for (int i = 0; i < OPTIMIZE_MAX_RETRY; ++i) {
      try {
        return super.put(key, 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.