annotate core/modules/comment/src/Plugin/Action/SaveComment.php @ 5:12f9dff5fda9
tip
Update to Drupal core 8.7.1
author |
Chris Cannam |
date |
Thu, 09 May 2019 15:34:47 +0100 |
parents |
c75dbcec494b |
children |
|
rev |
line source |
Chris@0
|
1 <?php
|
Chris@0
|
2
|
Chris@0
|
3 namespace Drupal\comment\Plugin\Action;
|
Chris@0
|
4
|
Chris@0
|
5 use Drupal\Component\Datetime\TimeInterface;
|
Chris@0
|
6 use Drupal\Core\Action\Plugin\Action\SaveAction;
|
Chris@0
|
7 use Drupal\Core\Entity\EntityTypeManagerInterface;
|
Chris@0
|
8
|
Chris@0
|
9 /**
|
Chris@0
|
10 * Saves a comment.
|
Chris@0
|
11 *
|
Chris@0
|
12 * @deprecated in Drupal 8.5.x, to be removed before Drupal 9.0.0.
|
Chris@0
|
13 * Use \Drupal\Core\Action\Plugin\Action\SaveAction instead.
|
Chris@0
|
14 *
|
Chris@0
|
15 * @see \Drupal\Core\Action\Plugin\Action\SaveAction
|
Chris@0
|
16 * @see https://www.drupal.org/node/2919303
|
Chris@0
|
17 *
|
Chris@0
|
18 * @Action(
|
Chris@0
|
19 * id = "comment_save_action",
|
Chris@0
|
20 * label = @Translation("Save comment"),
|
Chris@0
|
21 * type = "comment"
|
Chris@0
|
22 * )
|
Chris@0
|
23 */
|
Chris@0
|
24 class SaveComment extends SaveAction {
|
Chris@0
|
25
|
Chris@0
|
26 /**
|
Chris@0
|
27 * {@inheritdoc}
|
Chris@0
|
28 */
|
Chris@0
|
29 public function __construct($configuration, $plugin_id, $plugin_definition, EntityTypeManagerInterface $entity_type_manager, TimeInterface $time) {
|
Chris@0
|
30 parent::__construct($configuration, $plugin_id, $plugin_definition, $entity_type_manager, $time);
|
Chris@0
|
31 @trigger_error(__NAMESPACE__ . '\SaveComment is deprecated in Drupal 8.5.x, will be removed before Drupal 9.0.0. Use \Drupal\Core\Action\Plugin\Action\SaveAction instead. See https://www.drupal.org/node/2919303.', E_USER_DEPRECATED);
|
Chris@0
|
32 }
|
Chris@0
|
33
|
Chris@0
|
34 }
|