public function NodeViewSubscriber::__construct in Open Social 8.8
Same name and namespace in other branches
- 8.9 modules/custom/social_node_statistics/src/EventSubscriber/NodeViewSubscriber.php \Drupal\social_node_statistics\EventSubscriber\NodeViewSubscriber::__construct()
- 8.4 modules/custom/social_node_statistics/src/EventSubscriber/NodeViewSubscriber.php \Drupal\social_node_statistics\EventSubscriber\NodeViewSubscriber::__construct()
- 8.5 modules/custom/social_node_statistics/src/EventSubscriber/NodeViewSubscriber.php \Drupal\social_node_statistics\EventSubscriber\NodeViewSubscriber::__construct()
- 8.6 modules/custom/social_node_statistics/src/EventSubscriber/NodeViewSubscriber.php \Drupal\social_node_statistics\EventSubscriber\NodeViewSubscriber::__construct()
- 8.7 modules/custom/social_node_statistics/src/EventSubscriber/NodeViewSubscriber.php \Drupal\social_node_statistics\EventSubscriber\NodeViewSubscriber::__construct()
Constructor.
Parameters
\Drupal\Core\Database\Connection $database: The database connection.
\Drupal\Core\Session\AccountProxyInterface $account: The user account.
\Drupal\Core\Routing\CurrentRouteMatch $matcher: The route matcher.
\Drupal\Component\Datetime\TimeInterface $time: The system time.
File
- modules/
custom/ social_node_statistics/ src/ EventSubscriber/ NodeViewSubscriber.php, line 62
Class
- NodeViewSubscriber
- Class NodeViewSubscriber.
Namespace
Drupal\social_node_statistics\EventSubscriberCode
public function __construct(Connection $database, AccountProxyInterface $account, CurrentRouteMatch $matcher, TimeInterface $time) {
$this->database = $database;
$this->account = $account;
$this->routeMatcher = $matcher;
$this->time = $time;
}