You are here

public function SensorPluginBase::calculateDependencies in Monitoring 8

Calculates dependencies for the configured plugin.

Dependencies are saved in the plugin's configuration entity and are used to determine configuration synchronization order. For example, if the plugin integrates with specific user roles, this method should return an array of dependencies listing the specified roles.

array(
  'entity' => array(
    'user.role.anonymous',
    'user.role.authenticated',
  ),
  'module' => array(
    'node',
    'user',
  ),
  'theme' => array(
    'seven',
  ),
);

Return value

array An array of dependencies grouped by type (module, theme, entity). For example:

Overrides SensorPluginInterface::calculateDependencies

See also

\Drupal\Core\Config\Entity\ConfigDependencyManager

\Drupal\Core\Config\Entity\ConfigEntityInterface::getConfigDependencyName()

1 call to SensorPluginBase::calculateDependencies()
DatabaseAggregatorSensorPlugin::calculateDependencies in src/Plugin/monitoring/SensorPlugin/DatabaseAggregatorSensorPlugin.php
Calculates dependencies for the configured plugin.
4 methods override SensorPluginBase::calculateDependencies()
ConfigValueSensorPlugin::calculateDependencies in src/Plugin/monitoring/SensorPlugin/ConfigValueSensorPlugin.php
Calculates dependencies for the configured plugin.
ContentEntityAggregatorSensorPlugin::calculateDependencies in src/Plugin/monitoring/SensorPlugin/ContentEntityAggregatorSensorPlugin.php
Calculates dependencies for the configured plugin.
CoreRequirementsSensorPlugin::calculateDependencies in src/Plugin/monitoring/SensorPlugin/CoreRequirementsSensorPlugin.php
Calculates dependencies for the configured plugin.
DatabaseAggregatorSensorPlugin::calculateDependencies in src/Plugin/monitoring/SensorPlugin/DatabaseAggregatorSensorPlugin.php
Calculates dependencies for the configured plugin.

File

src/SensorPlugin/SensorPluginBase.php, line 133
Contains \Drupal\monitoring\SensorPlugin\SensorPluginBase.

Class

SensorPluginBase
Abstract SensorPluginInterface implementation with common behaviour and will be extended by sensor plugins.

Namespace

Drupal\monitoring\SensorPlugin

Code

public function calculateDependencies() {
  return array();
}