@@ -453,7 +453,7 @@ public function alias(string $tableChain, string $alias): static
453453 */
454454 public function aggregation (string $ function , ?string $ groupFunction = null ): mixed
455455 {
456- $ selection = $ this ->createSelectionInstance ( );
456+ $ selection = $ this ->explorer -> table ( $ this -> name );
457457 $ selection ->getSqlBuilder ()->importConditions ($ this ->getSqlBuilder ());
458458 if ($ groupFunction && $ selection ->getSqlBuilder ()->importGroupConditions ($ this ->getSqlBuilder ())) {
459459 $ selection ->select ("$ function AS aggregate " );
@@ -542,7 +542,7 @@ protected function execute(): void
542542 $ this ->rows = [];
543543 $ usedPrimary = true ;
544544 while ($ row = @$ result ->fetchAssoc ()) { // @ may contain duplicate columns
545- $ row = $ this ->createRow ( $ row );
545+ $ row = $ this ->explorer -> createActiveRow ( $ this , $ row );
546546 $ usedPrimary = $ usedPrimary && ($ primary = $ row ->getSignature (throw: false )) !== '' ;
547547 $ this ->rows [$ usedPrimary ? $ primary : $ key ++] = $ row ;
548548 }
@@ -557,24 +557,11 @@ protected function execute(): void
557557 }
558558
559559
560- /** @deprecated */
561- protected function createRow (array $ row ): ActiveRow
562- {
563- return $ this ->explorer ->createActiveRow ($ row , $ this );
564- }
565-
566-
567560 /** @deprecated */
568561 public function createSelectionInstance (?string $ table = null ): self
569562 {
570- return $ this ->explorer ->table ($ table ?: $ this ->name );
571- }
572-
573-
574- /** @deprecated */
575- protected function createGroupedSelectionInstance (string $ table , string $ column ): GroupedSelection
576- {
577- return $ this ->explorer ->createGroupedSelection ($ this , $ table , $ column );
563+ // DELETE
564+ return $ this ->explorer ->table ($ table ?? $ this ->name );
578565 }
579566
580567
@@ -835,7 +822,7 @@ public function insert(iterable $data): ActiveRow|array|int|bool
835822 return $ return ->getRowCount ();
836823 }
837824
838- $ row = $ this ->createSelectionInstance ( )
825+ $ row = $ this ->explorer -> table ( $ this -> name )
839826 ->select ('* ' )
840827 ->wherePrimary ($ primaryKey )
841828 ->fetch ();
@@ -924,7 +911,7 @@ public function getReferencedTable(ActiveRow $row, ?string $table, ?string $colu
924911 }
925912
926913 if ($ cacheKeys ) {
927- $ selection = $ this ->createSelectionInstance ($ table );
914+ $ selection = $ this ->explorer -> table ($ table );
928915 $ selection ->where ($ selection ->getPrimary (), array_keys ($ cacheKeys ));
929916 } else {
930917 $ selection = [];
@@ -957,7 +944,7 @@ public function getReferencingTable(
957944
958945 $ prototype = &$ this ->refCache ['referencingPrototype ' ][$ this ->getSpecificCacheKey ()]["$ table. $ column " ];
959946 if (!$ prototype ) {
960- $ prototype = $ this ->createGroupedSelectionInstance ($ table , $ column );
947+ $ prototype = $ this ->explorer -> createGroupedSelectionInstance ($ this , $ table , $ column );
961948 $ prototype ->where ("$ table. $ column " , array_keys ((array ) $ this ->rows ));
962949 $ prototype ->getSpecificCacheKey ();
963950 }
0 commit comments