本文整理汇总了PHP中Zend_Db_Select::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP Zend_Db_Select::__construct方法的具体用法?PHP Zend_Db_Select::__construct怎么用?PHP Zend_Db_Select::__construct使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Zend_Db_Select
的用法示例。
在下文中一共展示了Zend_Db_Select::__construct方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
/**
* Class constructor
* Add straight join support
*
* @param Zend_Db_Adapter_Abstract $adapter
*/
public function __construct(Zend_Db_Adapter_Abstract $adapter)
{
if (!isset(self::$_partsInit[self::STRAIGHT_JOIN])) {
self::$_partsInit = array(self::STRAIGHT_JOIN => false) + self::$_partsInit;
}
parent::__construct($adapter);
}
示例2: __construct
/**
* Class constructor
* Add straight join support
*
* @param \Magento\Framework\DB\Adapter\Pdo\Mysql $adapter
*/
public function __construct(\Magento\Framework\DB\Adapter\Pdo\Mysql $adapter)
{
if (!isset(self::$_partsInit[self::STRAIGHT_JOIN])) {
self::$_partsInit = [self::STRAIGHT_JOIN => false] + self::$_partsInit;
}
parent::__construct($adapter);
}
示例3: __construct
public function __construct($table, $adapter = false)
{
$this->adapter = $adapter ? $adapter : YARR_Abstract::getAdapter();
$this->class = false;
parent::__construct($this->adapter);
$this->from($table);
}
示例4: __construct
/**
* Class constructor
*
* @param Zend_Db_Adapter_Abstract $adapter
*/
public function __construct(Zend_Db_Adapter_Abstract $adapter)
{
parent::__construct($adapter);
if (!in_array(self::STRAIGHT_JOIN_ON, self::$_joinTypes)) {
self::$_joinTypes[] = self::STRAIGHT_JOIN_ON;
self::$_partsInit = array(self::STRAIGHT_JOIN => false) + self::$_partsInit;
}
}
示例5: __construct
/**
* Class constructor
* Add straight join support
*
* @param Adapter\Pdo\Mysql $adapter
* @param Select\SelectRenderer $selectRenderer
* @param array $parts
*/
public function __construct(\Magento\Framework\DB\Adapter\Pdo\Mysql $adapter, \Magento\Framework\DB\Select\SelectRenderer $selectRenderer, $parts = [])
{
self::$_partsInit = array_merge(self::$_partsInit, $parts);
if (!isset(self::$_partsInit[self::STRAIGHT_JOIN])) {
self::$_partsInit = [self::STRAIGHT_JOIN => false] + self::$_partsInit;
}
$this->selectRenderer = $selectRenderer;
parent::__construct($adapter);
}
示例6: __construct
/**
* @param Zend_Db_Adapter $adapter (optional) Adapter to use instead of the
* one set up by Omeka.
*/
public function __construct($adapter = null)
{
if (!$adapter) {
//Omeka's connection to the Zend_Db_Adapter
if (!($db = Zend_Registry::get('bootstrap')->getResource('Db'))) {
throw new RuntimeException("Unable to retrieve Omeka_Db instance.");
}
$adapter = $db->getAdapter();
}
return parent::__construct($adapter);
}
示例7: __construct
public function __construct($adapter, $sqloptions)
{
parent::__construct($adapter);
// set limit
if (!empty($sqloptions['limit'])) {
if (!empty($sqloptions['start'])) {
$start = $sqloptions['start'];
} else {
$start = 0;
}
$this->limit($sqloptions['limit'], $start);
}
// set order
if (!empty($sqloptions['order'])) {
$this->order($sqloptions['order']);
}
// set or where statement
$this->setWhere($sqloptions);
// set where statement
$this->setOrWhere($sqloptions);
}
示例8: __construct
/**
* Class constructor
*
* @param Zend_Db_Table_Abstract $adapter
*/
public function __construct(Zend_Db_Table_Abstract $table)
{
parent::__construct($table->getAdapter());
$this->setTable($table);
}
示例9: __construct
/**
* Class constructor
*
* @param Zend_Db_Adapter_Abstract $adapter
*/
public function __construct(Zend_Db_Adapter_Abstract $adapter)
{
parent::__construct($adapter);
}
示例10: __construct
public function __construct($selectObject, $db)
{
$x = parent::__construct($db);
$this->_parts = $selectObject->_parts;
}
示例11: __construct
/**
* Class constructor
*
* @param Kwf_Db_Table $table
*/
public function __construct(Kwf_Db_Table $table)
{
parent::__construct($table->getAdapter());
$this->_table = $table;
}