當前位置: 首頁>>代碼示例>>PHP>>正文


PHP DboSource::__construct方法代碼示例

本文整理匯總了PHP中DboSource::__construct方法的典型用法代碼示例。如果您正苦於以下問題:PHP DboSource::__construct方法的具體用法?PHP DboSource::__construct怎麽用?PHP DboSource::__construct使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在DboSource的用法示例。


在下文中一共展示了DboSource::__construct方法的8個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: array

 /**
  * construct method
  *
  * By default don't try to connect until you need to
  *
  * @param array $config Configuration array
  * @param bool $autoConnect false
  * @return void
  * @access public
  */
 function __construct($config = array(), $autoConnect = false) {
     return parent::__construct($config, $autoConnect);
 }
開發者ID:nishant-shrivastava,項目名稱:test-mongo-db,代碼行數:13,代碼來源:mongodb_source.php

示例2:

 /**
  * MS SQL DBO driver constructor; sets SQL Server error reporting defaults
  *
  * @param array $config Configuration data from app/config/databases.php
  * @return boolean True if connected successfully, false on error
  */
 function __construct($config, $autoConnect = true)
 {
     if ($autoConnect) {
         if (!function_exists('mssql_min_message_severity')) {
             trigger_error("PHP SQL Server interface is not installed, cannot continue.  For troubleshooting information, see http://php.net/mssql/", E_USER_WARNING);
         }
         mssql_min_message_severity(15);
         mssql_min_error_severity(2);
     }
     return parent::__construct($config, $autoConnect);
 }
開發者ID:adaptivertc,項目名稱:mosat,代碼行數:17,代碼來源:dbo_mssql.php

示例3:

 /**
  * MS SQLSRV DBO driver constructor
  *
  * @param array $config Configuration data from app/config/databases.php
  * @return boolean True if connected successfully, false on error
  */
 function __construct($config, $autoConnect = true)
 {
     return parent::__construct($config, $autoConnect);
 }
開發者ID:xplico,項目名稱:xplico,代碼行數:10,代碼來源:dbo_sqlsrv.php

示例4: Folder

 /**
  * コンストラクタ
  *
  * @param 	array 接続設定
  * @param boolean 自動接続の有無
  * @return void
  * @access private
  */
 function __construct($config = null, $autoConnect = true)
 {
     // TODO 現在の仕様として、$connected は、配列にしてしまっているので、
     // 次の処理を行うと処理がうまくいかなくなってしまう。
     // 配列の接続データは別のプロパティに持たせるようにした方が?
     /*if($autoConnect){
     			$folder = new Folder();
     			$this->connected = $folder->create($config['database']);
     		}*/
     parent::__construct($config, false);
     $this->appEncoding = Configure::read('App.encoding');
 }
開發者ID:nojimage,項目名稱:basercms,代碼行數:20,代碼來源:dbo_csv.php

示例5:

 /**
  * construct method
  *
  * By default don't try to connect until you need to
  *
  * @param array $config Configuration array
  * @param bool $autoConnect false
  * @access public
  */
 function __construct($config = [], $autoConnect = false)
 {
     parent::__construct($config, $autoConnect);
 }
開發者ID:pdedkov,項目名稱:cakephp-mongo,代碼行數:13,代碼來源:MongoDbSource.php

示例6:

 /**
  * SQLSRV DBO driver constructor; sets SQL Server error reporting defaults
  *
  * @param array $config Configuration data from app/config/databases.php
  * @return boolean True if connected successfully, false on error
  */
 function __construct($config, $autoConnect = true)
 {
     if ($autoConnect) {
         if (!function_exists('sqlsrv_configure')) {
             trigger_error(__("PHP SQL Server interface is not installed, cannot continue. For troubleshooting information, see http://msdn.microsoft.com/en-us/library/ee229551(v=SQL.10).aspx", true), E_USER_WARNING);
         }
         sqlsrv_configure('LogSeverity', 1);
     }
     return parent::__construct($config, $autoConnect);
 }
開發者ID:nriccitelli,項目名稱:CakePHP-sqlsrv-driver,代碼行數:16,代碼來源:dbo_sqlsrv.php

示例7:

 /**
  * MS SQL DBO driver constructor; sets SQL Server error reporting defaults
  *
  * @param array $config Configuration data from app/config/databases.php
  * @return boolean True if connected successfully, false on error
  */
 function __construct($config, $autoConnect = true)
 {
     if ($autoConnect) {
         if (!function_exists('sqlsrv_connect')) {
             trigger_error(__("PHP SQL Server interface is not installed, cannot continue. For troubleshooting information, see MSDN", true), E_USER_WARNING);
         }
     }
     return parent::__construct($config, $autoConnect);
 }
開發者ID:knightdna,項目名稱:miscellaneous,代碼行數:15,代碼來源:dbo_sqlsrv.php

示例8: __construct

 /**
  * Constructor
  *
  * @param array $config Configuration array
  * @access public
  */
 public function __construct($config = array())
 {
     parent::__construct($config);
     $this->connect();
 }
開發者ID:r0mk1n,項目名稱:cakephp-mongodb,代碼行數:11,代碼來源:mongodb_source.php


注:本文中的DboSource::__construct方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。