Example #1
0
 /**
  * Returns an ArangoDB-PHP document object representing this pod.
  * @return \triagens\ArangoDb\Document
  */
 public function toDriverDocument()
 {
     $document = new \triagens\ArangoDb\Document();
     foreach ($this->_data as $key => $value) {
         $document->set($key, $value);
     }
     if ($this->_id) {
         $document->setInternalId($this->_id);
     }
     if ($this->_key) {
         $document->setInternalKey($this->_key);
     }
     if ($this->_rev) {
         $document->setRevision($this->_rev);
     }
     return $document;
 }