• Main Page
  • Related Pages
  • Namespaces
  • Data Structures
  • Files
  • Examples
  • File List

E:/E/GEAMP/www/openbiz/openbiz/others/Zend/Db/Table.php

00001 <?php
00026 require_once 'Zend/Db/Table/Abstract.php';
00027 
00031 require_once 'Zend/Db/Table/Definition.php';
00032 
00042 class Zend_Db_Table extends Zend_Db_Table_Abstract
00043 {
00044 
00052     public function __construct($config = array(), $definition = null)
00053     {
00054         if ($definition !== null && is_array($definition)) {
00055             $definition = new Zend_Db_Table_Definition($definition);
00056         }
00057 
00058         if (is_string($config)) {
00059             if (Zend_Registry::isRegistered($config)) {
00060                 trigger_error(__CLASS__ . '::' . __METHOD__ . '(\'registryName\') is not valid usage of Zend_Db_Table, '
00061                     . 'try extending Zend_Db_Table_Abstract in your extending classes.',
00062                     E_USER_NOTICE
00063                     );
00064                 $config = array(self::ADAPTER => $config);
00065             } else {
00066                 // process this as table with or without a definition
00067                 if ($definition instanceof Zend_Db_Table_Definition
00068                     && $definition->hasTableConfig($config)) {
00069                     // this will have DEFINITION_CONFIG_NAME & DEFINITION
00070                     $config = $definition->getTableConfig($config);
00071                 } else {
00072                     $config = array(self::NAME => $config);
00073                 }
00074             }
00075         }
00076 
00077         parent::__construct($config);
00078     }
00079 
00080 
00081 
00082 
00083 
00084 }

Generated on Thu Apr 19 2012 17:01:17 for openbiz by  doxygen 1.7.2