Esempio n. 1
0
 /**
  * Create a new INI repository object
  *
  * @param   Config  $ds         The data source to use
  *
  * @throws  ProgrammingError    In case the given data source does not provide a valid key column
  */
 public function __construct(Config $ds)
 {
     parent::__construct($ds);
     // First! Due to init().
     if (!$ds->getConfigObject()->getKeyColumn()) {
         throw new ProgrammingError('INI repositories require their data source to provide a valid key column');
     }
 }
Esempio n. 2
0
 /**
  * Create a new DB repository object
  *
  * In case $this->queryColumns has already been initialized, this initializes
  * $this->caseInsensitiveColumns in case of a PostgreSQL connection.
  *
  * @param   DbConnection    $ds     The datasource to use
  */
 public function __construct(DbConnection $ds)
 {
     parent::__construct($ds);
     if ($ds->getDbType() === 'pgsql' && $this->queryColumns !== null) {
         $this->queryColumns = $this->removeCollateInstruction($this->queryColumns);
     }
 }
Esempio n. 3
0
 /**
  * Create a new LDAP repository object
  *
  * @param   LdapConnection  $ds     The data source to use
  */
 public function __construct(LdapConnection $ds)
 {
     parent::__construct($ds);
 }
 /**
  * Create a new Elasticsearch repository object
  *
  * @param   RestApiClient   $ds     The datasource to use
  */
 public function __construct(RestApiClient $ds)
 {
     parent::__construct($ds);
 }