icingaweb2-module-businessp.../library/Businessprocess/NodeRemoveAction.php

30 lines
488 B
PHP
Raw Normal View History

2015-03-16 04:08:00 -04:00
<?php
namespace Icinga\Module\Businessprocess;
/**
* NodeRemoveAction
*
* Tracks removed nodes
*
* @package Icinga\Module\Businessprocess
*/
2015-03-16 04:08:00 -04:00
class NodeRemoveAction extends NodeAction
{
/**
* @inheritdoc
*/
2015-03-16 04:08:00 -04:00
public function appliesTo(BusinessProcess $bp)
{
return $bp->hasNode($this->getNodeName());
}
/**
* @inheritdoc
*/
2015-03-16 04:08:00 -04:00
public function applyTo(BusinessProcess $bp)
{
$bp->removeNode($this->getNodeName());
}
}