if ($schema_handler->
tableExists($table_name)) { $schema_handler->
dropTable($table_name);
} } // Delete the field schema data.
foreach ($this->fieldStorageDefinitions
as $field_storage_definition) { $this->
deleteFieldSchemaData($field_storage_definition);
} // Delete the entity schema.
$this->
deleteEntitySchemaData($entity_type);
} /**
* {@inheritdoc}
*/
public function onFieldableEntityTypeCreate(EntityTypeInterface
$entity_type, array
$field_storage_definitions) { // When installing a fieldable entity type, we have to use the provided
// entity type and field storage definitions.
$this->entityType =
$entity_type;
$this->fieldStorageDefinitions =
$field_storage_definitions;