Exemple #1
0
 /**
  * Constructor for \Phalcon\Db\Adapter\Pdo
  *
  * @param array $descriptor
  * @throws Exception
  */
 public function __construct($descriptor)
 {
     if (is_array($descriptor) === false) {
         throw new Exception('The descriptor must be an array');
     }
     $this->connect($descriptor);
     parent::__construct($descriptor);
 }
 /**
  * Creates new Cassandra adapter
  * @param array $descriptor - connection description
  */
 public function __construct($descriptor)
 {
     $this->_transactionLevel = 0;
     $this->_type = 'cassandra';
     $this->_dialectType = 'cassandra';
     $this->_schemaCache = array();
     if (empty($descriptor['dialectClass'])) {
         $descriptor['dialectClass'] = 'PhalconCassandra\\Db\\Dialect\\Cassandra';
     }
     parent::__construct($descriptor);
 }