99use Ublaboo \DataGrid \Utils \DateTimeHelper ;
1010use Ublaboo \DataGrid \DataSource \IDataSource ;
1111
12- class QueryObjectDataSource implements IDataSource {
13-
14- use \Nette \SmartObject;
15-
16- /** @var \ADT\BaseQuery\ResultSet */
12+ class QueryObjectDataSource implements IDataSource
13+ {
14+ /** @var \ADT\DoctrineComponents\ResultSet */
1715 protected $ resultSet ;
1816
1917 /** @var \Doctrine\ORM\EntityRepository */
2018 protected $ repo ;
2119
22- /** @var \ADT\BaseQuery \QueryObject|IQueryObject */
20+ /** @var \ADT\DoctrineComponents \QueryObject|IQueryObject */
2321 protected $ queryObject ;
2422
2523 /** @var callable */
@@ -39,11 +37,11 @@ class QueryObjectDataSource implements IDataSource {
3937
4038 /**
4139 * QueryObjectDataSource constructor.
42- * @param \ADT\BaseQuery \QueryObject $queryObject
40+ * @param \ADT\DoctrineComponents \QueryObject $queryObject
4341 * @param \Doctrine\ORM\EntityRepository|null $repo
4442 * @throws \Exception
4543 */
46- public function __construct (\ADT \BaseQuery \QueryObject $ queryObject , \Doctrine \ORM \EntityRepository $ repo = null )
44+ public function __construct (\ADT \DoctrineComponents \QueryObject $ queryObject , \Doctrine \ORM \EntityRepository $ repo = null )
4745 {
4846 if (!$ repo && (!$ queryObject instanceof IQueryObject)) {
4947 throw new \Exception ('"repo" must be set or "queryObject" has to implement IQueryObject interface. ' );
@@ -173,7 +171,7 @@ public function filterOne(array $filter): IDataSource {
173171 * @param int $limit
174172 * @return static
175173 */
176- public function limit ($ offset , $ limit ): IDataSource {
174+ public function limit (int $ offset , int $ limit ): IDataSource {
177175 $ defaultCallback = function () use ($ offset , $ limit ) {
178176 $ this ->getResultSet ()->applyPaging ($ offset , $ limit );
179177 };
0 commit comments