diff --git a/src/ZfcBase/Mapper/AbstractDbMapper.php b/src/ZfcBase/Mapper/AbstractDbMapper.php index 2c8b36c..2f60617 100644 --- a/src/ZfcBase/Mapper/AbstractDbMapper.php +++ b/src/ZfcBase/Mapper/AbstractDbMapper.php @@ -119,6 +119,19 @@ protected function select(Select $select, $entityPrototype = null, HydratorInter return $resultSet; } + /** + * @return array + */ + public function getAll() + { + $dbresult = $this->select($this->getSelect()); + $result = array(); + while($dbresult && $entity = $dbresult->current()) { + $result[] = $entity; + } + return $result; + } + /** * @param object|array $entity * @param string|TableIdentifier|null $tableName