<?php/**
* @file
* Definition of Drupal\entity_test\EntityTestRevStorageController.
*/namespaceDrupal\entity_test;
useDrupal\entity_test\EntityTestStorageController;
/**
* Defines the controller class for the test entity.
*
* This extends the Drupal\entity_test\EntityTestStorageController class, adding
* required special handling for test entities with revision support.
*/class EntityTestRevStorageControllerextends EntityTestStorageController {
/**
* Overrides \Drupal\entity_test\EntityTestStorageController::baseFieldDefinitions().
*/
public functionbaseFieldDefinitions() {
$fields = parent::baseFieldDefinitions();
$fields['revision_id'] = array(
'label' => t('ID'),
'description' => t('The version id of the test entity.'),
'type' => 'integer_field',
'read-only' => TRUE,
);
return$fields;
}
}