databoxConnectionProvider = $connectionProvider; $this->collectionFactory = $collectionFactory; $this->collectionReferenceRepository = $referenceRepository; } /** * @param int $databoxId * @return CollectionRepository */ public function createRepositoryForDatabox($databoxId) { $databoxConnection = $this->databoxConnectionProvider->getConnection($databoxId); return new DbalCollectionRepository( $databoxId, $databoxConnection, $this->collectionReferenceRepository, $this->collectionFactory ); } }