<?php
/**
* A common interface for SQL-based entity storage implementations.
*/
interface SqlEntityStorageInterface {
/**
* Gets a table mapping for the entity's SQL tables.
*
* @param \Drupal\Core\Field\FieldStorageDefinitionInterface[] $storage_definitions
* (optional) An array of field storage definitions to be used to compute
* the table mapping. Defaults to the ones provided by the entity manager.
*
* @return \Drupal\Core\Entity\Sql\TableMappingInterface
* A table mapping object for the entity's tables.
*/
public function getTableMapping(array $storage_definitions = NULL, $entity_type = NULL);
}
class C implements SqlEntityStorageInterface {
public function getTableMapping(array $storage_definitions = NULL) {
}
}
$c = new C();
Deprecated: SqlEntityStorageInterface::getTableMapping(): Implicitly marking parameter $storage_definitions as nullable is deprecated, the explicit nullable type must be used instead in /in/oZ8HH on line 18
Deprecated: C::getTableMapping(): Implicitly marking parameter $storage_definitions as nullable is deprecated, the explicit nullable type must be used instead in /in/oZ8HH on line 23
Fatal error: Declaration of C::getTableMapping(?array $storage_definitions = null) must be compatible with SqlEntityStorageInterface::getTableMapping(?array $storage_definitions = null, $entity_type = null) in /in/oZ8HH on line 23
Process exited with code 255.
Fatal error: Declaration of C::getTableMapping(?array $storage_definitions = null) must be compatible with SqlEntityStorageInterface::getTableMapping(?array $storage_definitions = null, $entity_type = null) in /in/oZ8HH on line 23
Process exited with code 255.
Output for 7.4.0 - 7.4.33
Fatal error: Declaration of C::getTableMapping(?array $storage_definitions = NULL) must be compatible with SqlEntityStorageInterface::getTableMapping(?array $storage_definitions = NULL, $entity_type = NULL) in /in/oZ8HH on line 23
Process exited with code 255.
Fatal error: Declaration of C::getTableMapping(?array $storage_definitions = NULL) must be compatible with SqlEntityStorageInterface::getTableMapping(?array $storage_definitions = NULL, $entity_type = NULL) in /in/oZ8HH on line 22
Process exited with code 255.
Output for 7.0.33
Fatal error: Declaration of C::getTableMapping(array $storage_definitions = NULL) must be compatible with SqlEntityStorageInterface::getTableMapping(array $storage_definitions = NULL, $entity_type = NULL) in /in/oZ8HH on line 22
Process exited with code 255.
Output for 5.6.38
Fatal error: Declaration of C::getTableMapping() must be compatible with SqlEntityStorageInterface::getTableMapping(array $storage_definitions = NULL, $entity_type = NULL) in /in/oZ8HH on line 22
Process exited with code 255.