public function DiskUsageSensorPlugin::__construct in Monitoring 8
Instantiates a sensor object.
Parameters
\Drupal\monitoring\Entity\SensorConfig $sensor_config: Sensor config object.
string $plugin_id: The plugin_id for the plugin instance.
mixed $plugin_definition: The plugin implementation definition.
Overrides SensorPluginBase::__construct
File
- src/
Plugin/ monitoring/ SensorPlugin/ DiskUsageSensorPlugin.php, line 42
Class
- DiskUsageSensorPlugin
- Monitors disk space usage.
Namespace
Drupal\monitoring\Plugin\monitoring\SensorPluginCode
public function __construct(SensorConfig $sensor_config, $plugin_id, $plugin_definition, FileSystemInterface $file_system, StateInterface $state_system) {
parent::__construct($sensor_config, $plugin_id, $plugin_definition);
$this->fileSystem = $file_system;
$this->state = $state_system;
}