/** * @param FetcherInterface $fetcher * @param FetchConfig $fetchConfig * * @return array */ public function fetchAll(FetcherInterface $fetcher, FetchConfig $fetchConfig) { $fetchStyle = $fetchConfig->getFetchStyle(); if (!$this->hasRowsForFetchStyle($fetchStyle)) { $this->rows[$fetchStyle] = $fetcher->fetchAll($this->rows[CorePDO::FETCH_BOTH], $fetchConfig); } return $this->rows[$fetchStyle]; }
/** * @param FetchConfig $fetchConfig * * @return array * @throws Exception */ public function fetchAll(FetchConfig $fetchConfig) { $fetcher = $this->fetcherFactory->getByFetchStyle($fetchConfig->getFetchStyle()); if (!$this->isInitialized()) { $this->initialize(); } return $this->data->fetchAll($fetcher, $fetchConfig); }