@Override public Document createFieldValue() { return new Document(this, (DocumentId) null); }
public DocumentPut(DocumentType docType, DocumentId docId) { this.document = new Document(docType, docId); }
@Override public Document createFieldValue() { return new Document(null, (DocumentId)null); }
public DocumentPut(DocumentType docType, String docId) { this.document = new Document(docType, docId); }
public static Document createDocument(DocumentReader buffer) { return new Document(buffer); }
public Document createDocument(DocumentDeserializer data) { return new Document(data); }
final public Document createDocument(GrowableByteBuffer buf) { DocumentDeserializer data = DocumentDeserializerFactory.create6(this, buf); return new Document(data); } public Document createDocument(DocumentDeserializer data) {
public static Document newPartialDocument(DocumentType docType, DocumentId docId, Field field, ValueUpdate update) { Document doc = new Document(docType, docId); applyUpdate(field, update, doc); return doc; }
/** * Copy constructor * @param other DocumentPut to copy */ public DocumentPut(DocumentPut other) { super(other); this.document = new Document(other.getDocument()); }
public static Document newPartialDocument(DocumentId docId, FieldPathUpdate update) { Document doc = new Document(update.getDocumentType(), docId); applyUpdate(update, doc); return doc; }
public DocumentListEntry(DocumentDeserializer buf) { timestamp = buf.getLong(null); doc = new Document(buf); removeEntry = buf.getByte(null) > 0; }
public SimpleDocumentAdapter(Document input) { this(input, new Document(input.getDataType(), input.getId())); }
public Document createRandomDocumentAtLocation(long location, long timestamp, int minSize, int maxSize) { Document document = new Document(getDocumentType("testdoctype1"), new DocumentId("userdoc:footype:" + location + ":" + timestamp)); document.setFieldValue("headerval", new IntegerFieldValue((int)timestamp)); StringBuffer value = new StringBuffer(); int length = (int)(Math.random() * (maxSize - minSize)) + minSize; for (int i = 0; i < length; ++i) { value.append("A"); } document.setFieldValue("content", new StringFieldValue(value.toString())); return document; } }
switch (documentParseInfo.operationType) { case PUT: documentOperation = new DocumentPut(new Document(documentType, documentParseInfo.documentId)); readPut(documentParseInfo.fieldsBuffer, (DocumentPut) documentOperation); verifyEndState(documentParseInfo.fieldsBuffer, JsonToken.END_OBJECT);
public void RPC_put(Request req) { try { GrowableByteBuffer buffer = new GrowableByteBuffer(ByteBuffer.wrap(req.parameters().get(3).asData())); Document doc = new Document(DocumentDeserializerFactory.create42(docTypeManager, buffer)); addResult(provider.put(getBucket(req, 0), req.parameters().get(2).asInt64(), doc), req); } catch (Exception e) { e.printStackTrace(); throw new RuntimeException(e); } }
Document document = new Document(documentReader); operation.setDocument(document); operation.setCondition(TestAndSetCondition.fromConditionString(documentReader.getCondition()));
DocumentType docType = upd.getDocumentType(); DocumentId docId = upd.getId(); Document complete = new Document(docType, upd.getId()); for (FieldPathUpdate fieldUpd : upd) { try {