_sqlMap = NULL; return array(); } public static function getInstance() { $className = get_called_class(); if (!isset(static::$_instances[$className])) { static::$_instances[$className] = new static(); } return static::$_instances[$className]; } protected function getClient() { if (!$this->_sqlMap) { $this->_sqlMap = Prado::getApplication()->getModule('sqlmap')->Client; } return $this->_sqlMap; } protected function quoteString($string) { return $this->getClient()->DbConnection->quoteString($string); } protected function fetch($sqlMap, $params) { return $this->getClient()->queryForObject($sqlMap, $params); } protected function fetchList($sqlMap, $params) { return $this->getClient()->queryForList($sqlMap, $params); } protected function fetchMap($sqlMap, $params, $key, $value=NULL) { return $this->getClient()->queryForMap($sqlMap, $params, $key, $value); } } ?>