@@ -22,10 +22,10 @@ class SearchResult
2222 /**
2323 * Construct SearchResult
2424 *
25- * @param \PDOStatemen $res
26- * @param int $rangeBegin
27- * @param int $rangeEnd
28- * @param array $ columns
25+ * @param \PDOStatement $res PDO statement containing the search result
26+ * @param int $rangeBegin Begin of requested result range
27+ * @param int $rangeEnd End of requested result range
28+ * @param Column[] $columns Search columns
2929 * @param bool $pageidAndRevOnly
3030 */
3131 public function __construct ($ res , $ rangeBegin , $ rangeEnd , $ columns , $ pageidAndRevOnly )
@@ -55,13 +55,12 @@ public function __construct($res, $rangeBegin, $rangeEnd, $columns, $pageidAndRe
5555 continue ;
5656 }
5757
58- $ this ->addPid ( $ row ['PID ' ]) ;
59- $ this ->addRid ( $ row ['rid ' ]) ;
60- $ this ->addRev ( $ row ['rev ' ]) ;
61- $ this ->addRow ( $ resrow) ;
58+ $ this ->pids [] = $ row ['PID ' ];
59+ $ this ->rids [] = $ row ['rid ' ];
60+ $ this ->revs [] = $ row ['rev ' ];
61+ $ this ->rows [] = $ resrow ;
6262 }
6363
64- $ res ->closeCursor ();
6564 $ this ->increaseCount ();
6665 }
6766
@@ -105,42 +104,6 @@ public function getRevs(): array
105104 return $ this ->revs ;
106105 }
107106
108- /**
109- * @param string $pid
110- * @return void
111- */
112- public function addPid ($ pid )
113- {
114- $ this ->pids [] = $ pid ;
115- }
116-
117- /**
118- * @param int $rid
119- * @return void
120- */
121- public function addRid ($ rid )
122- {
123- $ this ->rids [] = $ rid ;
124- }
125-
126- /**
127- * @param int $rev
128- * @return void
129- */
130- public function addRev ($ rev )
131- {
132- $ this ->revs [] = $ rev ;
133- }
134-
135- /**
136- * @param array $result
137- * @return void
138- */
139- public function addRow ($ row )
140- {
141- $ this ->rows [] = $ row ;
142- }
143-
144107 /**
145108 * @return void
146109 */
0 commit comments