function SqlContentEntityStorageSchema::processIdentifierSchema
Same name in other branches
- 9 core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorageSchema.php \Drupal\Core\Entity\Sql\SqlContentEntityStorageSchema::processIdentifierSchema()
- 8.9.x core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorageSchema.php \Drupal\Core\Entity\Sql\SqlContentEntityStorageSchema::processIdentifierSchema()
- 11.x core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorageSchema.php \Drupal\Core\Entity\Sql\SqlContentEntityStorageSchema::processIdentifierSchema()
Processes the specified entity key.
Parameters
array $schema: The table schema, passed by reference.
string $key: The entity key name.
1 call to SqlContentEntityStorageSchema::processIdentifierSchema()
- SqlContentEntityStorageSchema::getSharedTableFieldSchema in core/
lib/ Drupal/ Core/ Entity/ Sql/ SqlContentEntityStorageSchema.php - Gets the schema for a single field definition.
File
-
core/
lib/ Drupal/ Core/ Entity/ Sql/ SqlContentEntityStorageSchema.php, line 1487
Class
- SqlContentEntityStorageSchema
- Defines a schema handler that supports revisionable, translatable entities.
Namespace
Drupal\Core\Entity\SqlCode
protected function processIdentifierSchema(&$schema, $key) {
if ($schema['fields'][$key]['type'] == 'int') {
$schema['fields'][$key]['type'] = 'serial';
}
$schema['fields'][$key]['not null'] = TRUE;
unset($schema['fields'][$key]['default']);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.