Maps from an entity object to the storage record of the revision table.
protected function mapToRevisionStorageRecord(EntityInterface $entity) {
$record = new \stdClass();
foreach ($this->entityInfo['schema_fields_sql']['revision_table'] as $name) {
$record->{$name} = $entity->{$name}->value;
}
return $record;
}