diff --git a/Connection.php b/Connection.php index b68c6aa..a99708c 100644 --- a/Connection.php +++ b/Connection.php @@ -4,6 +4,7 @@ namespace explosivebit\arangodb; use ArangoDBClient\EdgeHandler; use ArangoDBClient\Export; +use ArangoDBClient\GraphHandler; use Yii; use ArangoDBClient\CollectionHandler; use ArangoDBClient\ConnectionOptions; @@ -46,6 +47,8 @@ class Connection extends BaseObject private $documentHandler = null; /** @var null|EdgeHandler $documentHandler */ private $edgeHandler = null; + /** @var null|EdgeHandler $graphHandler */ + private $graphHandler = null; public function init() { @@ -59,6 +62,7 @@ class Connection extends BaseObject $this->collectionHandler = new CollectionHandler($this->connection); $this->documentHandler = new DocumentHandler($this->connection); $this->edgeHandler = new EdgeHandler($this->connection); + $this->graphHandler = new GraphHandler($this->connection); Yii::endProfile($token, 'explosivebit\arangodb\Connection::open'); } catch (\Exception $ex) { Yii::endProfile($token, 'explosivebit\arangodb\Connection::open'); @@ -66,6 +70,14 @@ class Connection extends BaseObject } } + /** + * @return EdgeHandler|null + */ + public function getGraphHandler(): EdgeHandler + { + return $this->graphHandler; + } + /** * @return null|CollectionHandler */