trait ArangoDocument[F[_]] extends AnyRef
Arango document API
- F
effect
- Alphabetic
- By Inheritance
- ArangoDocument
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Abstract Value Members
-
abstract
def
handle: DocumentHandle
document handle
-
abstract
def
head(ifNoneMatch: Option[String] = None, ifMatch: Option[String] = None, transaction: Option[TransactionId] = None): F[Header]
Like read, but only returns the header fields and not the body.
Like read, but only returns the header fields and not the body. You can use this call to get the current revision of a document or check if the document was deleted.
- ifNoneMatch
If the “If-None-Match” header is given, then it must contain exactly one Etag. If the current document revision is not equal to the specified Etag, an HTTP 200 response is returned. If the current document revision is identical to the specified Etag, then an HTTP 304 is returned.
- ifMatch
If the “If-Match” header is given, then it must contain exactly one Etag. The document is returned, if it has the same revision as the given Etag. Otherwise a HTTP 412 is returned.
-
abstract
def
read[T](ifNoneMatch: Option[String] = None, ifMatch: Option[String] = None, transaction: Option[TransactionId] = None)(implicit arg0: VPackDecoder[T]): F[ArangoResponse[T]]
Returns the document identified by *document-handle*.
Returns the document identified by *document-handle*. The returned document contains three special attributes: *_id* containing the document handle, *_key* containing key which uniquely identifies a document in a given collection and *_rev* containing the revision.
- T
The type of the document.
- ifNoneMatch
If the "If-None-Match" header is given, then it must contain exactly one Etag. The document is returned, if it has a different revision than the given Etag. Otherwise an HTTP 304 is returned.
- ifMatch
If the "If-Match" header is given, then it must contain exactly one Etag. The document is returned, if it has the same revision as the given Etag. Otherwise a HTTP 412 is returned.
-
abstract
def
remove[T](waitForSync: Boolean = false, returnOld: Boolean = false, silent: Boolean = false, ifMatch: Option[String] = None, transaction: Option[TransactionId] = None)(implicit arg0: VPackDecoder[T]): F[ArangoResponse[Document[T]]]
Removes a document
Removes a document
- T
Response body type
- waitForSync
Wait until deletion operation has been synced to disk.
- returnOld
Return additionally the complete previous revision of the changed document under the attribute old in the result.
- silent
If set to true, an empty object will be returned as response. No meta-data will be returned for the removed document. This option can be used to save some network traffic.
- ifMatch
You can conditionally remove a document based on a target revision id by using the if-match HTTP header.
-
abstract
def
replace[T](document: T, waitForSync: Boolean = false, ignoreRevs: Boolean = true, returnOld: Boolean = false, returnNew: Boolean = false, silent: Boolean = false, ifMatch: Option[String] = None, transaction: Option[TransactionId] = None)(implicit arg0: VPackEncoder[T], arg1: VPackDecoder[T]): F[ArangoResponse[Document[T]]]
- T
document type
- document
representation of a document update as an object
- waitForSync
Wait until document has been synced to disk. (optional)
- ignoreRevs
By default, or if this is set to *true*, the *_rev* attributes in the given document is ignored. If this is set to *false*, then the *_rev* attribute given in the body document is taken as a precondition. The document is only updated if the current revision is the one specified. (optional)
- returnOld
Return additionally the complete previous revision of the changed document under the attribute *old* in the result. (optional)
- returnNew
Return additionally the complete new document under the attribute *new* in the result. (optional)
- silent
If set to *true*, an empty object will be returned as response. No meta-data will be returned for the updated document. This option can be used to save some network traffic. (optional)
- ifMatch
You can conditionally update a document based on a target revision id by using the *if-match* HTTP header. (optional)
-
abstract
def
update[T, P](patch: P, keepNull: Boolean = false, mergeObjects: Boolean = true, waitForSync: Boolean = false, ignoreRevs: Boolean = true, returnOld: Boolean = false, returnNew: Boolean = false, silent: Boolean = false, ifMatch: Option[String] = None, transaction: Option[TransactionId] = None)(implicit arg0: VPackDecoder[T], arg1: VPackEncoder[P]): F[ArangoResponse[Document[T]]]
- T
document type
- P
patch type
- patch
representation of a document update as an object
- keepNull
If the intention is to delete existing attributes with the patch command, the URL query parameter *keepNull* can be used with a value of *false*. This will modify the behavior of the patch command to remove any attributes from the existing document that are contained in the patch document with an attribute value of *null*. (optional)
- mergeObjects
Controls whether objects (not arrays) will be merged if present in both the existing and the patch document. If set to *false*, the value in the patch document will overwrite the existing document's value. If set to *true*, objects will be merged. The default is *true*. (optional)
- waitForSync
Wait until document has been synced to disk. (optional)
- ignoreRevs
By default, or if this is set to *true*, the *_rev* attributes in the given document is ignored. If this is set to *false*, then the *_rev* attribute given in the body document is taken as a precondition. The document is only updated if the current revision is the one specified. (optional)
- returnOld
Return additionally the complete previous revision of the changed document under the attribute *old* in the result. (optional)
- returnNew
Return additionally the complete new document under the attribute *new* in the result. (optional)
- silent
If set to *true*, an empty object will be returned as response. No meta-data will be returned for the updated document. This option can be used to save some network traffic. (optional)
- ifMatch
You can conditionally update a document based on a target revision id by using the *if-match* HTTP header. (optional)
-
abstract
def
upsert(obj: VObject): ArangoQuery[F, VObject]
build an UPSERT query at key with INSERT+UPDATE from obj
build an UPSERT query at key with INSERT+UPDATE from obj
- obj
vpack object
- returns
query
Concrete Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()