Package com.orientechnologies.orient.core.record.impl

Examples of com.orientechnologies.orient.core.record.impl.ODocument.save()


        doc.setIdentity(recordId);

      if (!recordId.isValid())
        throw new IllegalArgumentException("Invalid Record ID in request: " + recordId);

      doc.save();

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


      for (int i = 0; i < fieldNames.size(); ++i) {
        doc.field(fieldNames.get(i), OSQLHelper.getValue(fieldValues[i], doc));
      }

      if (clusterName != null)
        doc.save(clusterName);
      else
        doc.save();
      return doc;
    }
  }
View Full Code Here

      }

      if (clusterName != null)
        doc.save(clusterName);
      else
        doc.save();
      return doc;
    }
  }
}
View Full Code Here

                  }
                  coll.add(doc);
                } else {
                  target.field(linkName, doc);
                }
                target.save();

              } else {
                // SET THE REFERENCE
                doc.field(linkName, value);
                doc.save();
View Full Code Here

        }

        doc.field(f.getKey(), newValue);
      }

      doc.save();
      sendTextContent(iRequest, OHttpUtils.STATUS_OK_CODE, "OK", null, OHttpUtils.CONTENT_TEXT_PLAIN, "Record " + rid
          + " updated successfully.");
    } else if ("add".equals(operation)) {
      iRequest.data.commandInfo = "Studio create document";
View Full Code Here

      // BIND ALL CHANGED FIELDS
      for (Entry<String, String> f : fields.entrySet())
        doc.field(f.getKey(), f.getValue());

      doc.save();
      sendTextContent(iRequest, 201, "OK", null, OHttpUtils.CONTENT_TEXT_PLAIN, "Record " + doc.getIdentity()
          + " updated successfully.");

    } else if ("del".equals(operation)) {
      iRequest.data.commandInfo = "Studio delete document";
View Full Code Here

        linkedClass = iLinkedClass;
      } else {
        document = (ODocument) o;

        if (document.getIdentity().isTemporary())
          document.save();

        linkedClass = document.getSchemaClass();
      }

      if (document != null && iLinkedType != OType.LINK)
View Full Code Here

      }
    }

    if (recordUpdated) {
      record.setDirty();
      record.save();
      recordCount++;
    }

    return true;
  }
View Full Code Here

                  }
                  coll.add(doc);
                } else {
                  target.field(linkName, doc);
                }
                target.save();

              } else {
                // SET THE REFERENCE
                doc.field(linkName, value);
                doc.save();
View Full Code Here

        linkedClass = iLinkedClass;
      } else {
        document = (ODocument) o;

        if (document.getIdentity().isTemporary())
          document.save();

        linkedClass = document.getSchemaClass();
      }

      if (document != null && iLinkedType != OType.LINK)
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.