_setupTableName() 보호된 메소드

If the table name is not set in the class definition, use the class name itself as the table name. A schema name provided with the table name (e.g., "schema.table") overrides any existing value for $this->_schema.
protected _setupTableName ( ) : void
리턴 void
예제 #1
0
 /**
  * Set name of table
  *
  */
 protected function _setupTableName()
 {
     if ($this->getRowClass()) {
         $this->_name = $this->getRowClass();
     }
     parent::_setupTableName();
 }
예제 #2
0
 /**
  * This will automatically set table name with prefix from bootstrap file
  * @return void
  */
 protected function _setupTableName()
 {
     parent::_setupTableName();
     if (Zend_Registry::isRegistered('tbl_prefix')) {
         $this->_name = Zend_Registry::get('tbl_prefix') . $this->_name;
     }
 }
예제 #3
0
 protected function _setupTableName()
 {
     if (defined('T_PREFIX')) {
         $this->_name = T_PREFIX . $this->_name;
     }
     parent::_setupTableName();
 }
예제 #4
0
파일: Table.php 프로젝트: html/PI
 protected function _setupTableName()
 {
     if (is_null($this->_name)) {
         $this->_name = strtolower(str_replace('Model', '', get_class($this)));
     }
     parent::_setupTableName();
 }
예제 #5
0
 protected function _setupTableName()
 {
     if (empty($this->_name)) {
         $className = get_class($this);
         if (strncmp(self::PREFIX, $className, self::PREFIX_LEN) == 0) {
             $this->_name = strtolower(substr($className, self::PREFIX_LEN));
         } else {
             $this->_name = strtolower($className);
         }
     }
     parent::_setupTableName();
 }
 /**
  * 
  * @return void
  */
 protected function _setupTableName()
 {
     parent::_setupTableName();
     $this->_name = Fox::getTablePrefix() . $this->_name;
 }
예제 #7
0
파일: Table.php 프로젝트: rcrrich/cunity
 /**
  * @throws \Exception
  */
 protected function _setupTableName()
 {
     $this->_config = Cunity::get("config");
     if ($this->_config->db->params->table_prefix !== '') {
         $this->_dbprefix = $this->_config->db->params->table_prefix . '_';
     }
     $this->_name = $this->_dbprefix . $this->_name;
     parent::_setupTableName();
 }
예제 #8
0
 /**
  * Initialize table and schema names.
  *
  * If the table name is not set in the class definition,
  * use the class name itself as the table name.
  *
  * A schema name provided with the table name (e.g., "schema.table") overrides
  * any existing value for $this->_schema.
  *
  * @return void
  */
 protected function _setupTableName()
 {
     parent::_setupTableName();
     $this->_prefix = Axis::config()->db->prefix;
     $this->_name = $this->_prefix . $this->_name;
 }
예제 #9
0
 /**
  * Translate our class name to a table name and setup it.
  * See Naming Conventions for more information.
  *
  * @return void
  */
 protected function _setupTableName()
 {
     $this->_name = $this->getTableName();
     parent::_setupTableName();
 }