* @license PHP License * @package WB * @subpackage db */ WBClass::load('WBDatasource_Renderer'); /** * Datasource renderer Array * * @version 0.1.0 * @package WB * @subpackage db */ class WBDatasource_Renderer_Array extends WBDatasource_Renderer { /** * list * @var array */ private $list = array(); /** * start rendering * * Flush current list */ public function start($view) { $this->list = array(); } /** * render single item * * The consumer for data source iteratrion * @param array $item */ public function renderItem($item) { $this->list[] = $item; } /** * finish rendering * * Things to do after iterating through datasource */ public function end() { } /** * get actual list * * @return array */ public function getList() { return $this->list; } }