/** * @param IDataSource $dataSource */ protected function setDataSource(IDataSource $dataSource) { $this->dataSource = $dataSource; $this->primaryKey = $this->dataSource->getPrimaryKey(); }