Beispiel #1
0
 /**
  * @param array $query
  */
 public function findOne(array $query = [])
 {
     $result = $this->getCollection()->findOne($query);
     return $result ? Echidna::document($this->getDocument(), $result, false, $this, ['after_get']) : null;
 }
Beispiel #2
0
 /**
  * @param string|\DataEntity\TypeInterface $type
  *
  * @return \DataEntity\TypeInterface
  */
 protected function getType($type)
 {
     return Echidna::type($type);
 }