public function DefaultTableMapping::setExtraColumns in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/lib/Drupal/Core/Entity/Sql/DefaultTableMapping.php \Drupal\Core\Entity\Sql\DefaultTableMapping::setExtraColumns()
Adds a extra columns for a table to the table mapping.
Parameters
string $table_name: The name of table to add the extra columns for.
string[] $column_names: The list of column names.
Return value
$this
File
- core/
lib/ Drupal/ Core/ Entity/ Sql/ DefaultTableMapping.php, line 257 - Contains \Drupal\Core\Entity\Sql\DefaultTableMapping.
Class
- DefaultTableMapping
- Defines a default table mapping class.
Namespace
Drupal\Core\Entity\SqlCode
public function setExtraColumns($table_name, array $column_names) {
$this->extraColumns[$table_name] = $column_names;
// Force the re-computation of the column list.
unset($this->allColumns[$table_name]);
return $this;
}