toPairs() public static method

Reformat source to key -> value pairs.
public static toPairs ( array $rows, $key = NULL, $value = NULL ) : array
$rows array
return array
コード例 #1
0
ファイル: Selection.php プロジェクト: jave007/test
 /**
  * @inheritDoc
  */
 public function fetchPairs($key = NULL, $value = NULL)
 {
     return Nette\Database\Helpers::toPairs($this->fetchAll(), $key, $value);
 }
コード例 #2
0
ファイル: Selection.php プロジェクト: jurasm2/nette
 /**
  * @inheritDoc
  */
 public function fetchPairs($key = NULL, $value = NULL)
 {
     return Nette\Database\Helpers::toPairs(iterator_to_array($this), $key, $value);
 }