public function CommentStatisticsInterface::create in Drupal 9
Same name and namespace in other branches
- 8 core/modules/comment/src/CommentStatisticsInterface.php \Drupal\comment\CommentStatisticsInterface::create()
Insert an empty record for the given entity.
Parameters
\Drupal\Core\Entity\FieldableEntityInterface $entity: The created entity for which a statistics record is to be initialized.
array $fields: Array of comment field definitions for the given entity.
1 method overrides CommentStatisticsInterface::create()
- CommentStatistics::create in core/
modules/ comment/ src/ CommentStatistics.php - Insert an empty record for the given entity.
File
- core/
modules/ comment/ src/ CommentStatisticsInterface.php, line 79
Class
- CommentStatisticsInterface
- Provides an interface for storing and retrieving comment statistics.
Namespace
Drupal\commentCode
public function create(FieldableEntityInterface $entity, $fields);