class RulesTestEventHandler

Test event handler class.

Hierarchy

Expanded class hierarchy of RulesTestEventHandler

1 string reference to 'RulesTestEventHandler'
rules_test_rules_event_info in tests/rules_test.rules.inc
Implements hook_rules_event_info().

File

tests/rules_test.rules.inc, line 362

View source
class RulesTestEventHandler extends RulesEventDefaultHandler implements RulesEventDispatcherInterface {
    
    /**
     * Name of the variable in which to store the state of the event handler.
     *
     * @var string
     */
    protected $variableName = 'rules_test_event_handler_watch';
    
    /**
     * Implements RulesEventDispatcherInterface::startWatching().
     */
    public function startWatching() {
        variable_set($this->variableName, TRUE);
    }
    
    /**
     * Implements RulesEventDispatcherInterface::stopWatching().
     */
    public function stopWatching() {
        variable_set($this->variableName, FALSE);
    }
    
    /**
     * Implements RulesEventDispatcherInterface::isWatching().
     */
    public function isWatching() {
        return (bool) variable_get($this->variableName);
    }

}

Members

Title Sort descending Modifiers Object type Summary Overriden Title Overrides
RulesEventDefaultHandler::buildForm public function Implements RulesEventHandlerInterface::buildForm(). Overrides RulesEventHandlerInterface::buildForm
RulesEventDefaultHandler::getDefaults public function Implements RulesEventHandlerInterface::getDefaults(). Overrides RulesEventHandlerInterface::getDefaults
RulesEventDefaultHandler::getEventNameSuffix public function Implements RulesEventHandlerInterface::getConfiguredEventName(). Overrides RulesEventHandlerInterface::getEventNameSuffix
RulesEventDefaultHandler::getSettings public function Implements RulesEventHandlerInterface::getSettings(). Overrides RulesEventHandlerBase::getSettings
RulesEventDefaultHandler::summary public function Implements RulesEventHandlerInterface::summary(). Overrides RulesEventHandlerInterface::summary
RulesEventHandlerBase::$eventInfo protected property The event info.
RulesEventHandlerBase::$eventName protected property The event name.
RulesEventHandlerBase::$settings protected property The event settings.
RulesEventHandlerBase::availableVariables public function Implements RulesEventHandlerInterface::availableVariables(). Overrides RulesEventHandlerInterface::availableVariables 1
RulesEventHandlerBase::extractFormValues public function Implements RulesEventHandlerInterface::extractFormValues(). Overrides RulesEventHandlerInterface::extractFormValues 1
RulesEventHandlerBase::getEventInfo public function Implements RulesEventHandlerInterface::getEventInfo(). Overrides RulesEventHandlerInterface::getEventInfo
RulesEventHandlerBase::getEventName public function Implements RulesEventHandlerInterface::getEventName(). Overrides RulesEventHandlerInterface::getEventName
RulesEventHandlerBase::setSettings public function Implements RulesEventHandlerInterface::setSettings(). Overrides RulesEventHandlerInterface::setSettings
RulesEventHandlerBase::validate public function Implements RulesEventHandlerInterface::validate(). Overrides RulesEventHandlerInterface::validate 1
RulesEventHandlerBase::__construct public function Implements RulesEventHandlerInterface::__construct(). Overrides RulesEventHandlerInterface::__construct 1
RulesTestEventHandler::$variableName protected property Name of the variable in which to store the state of the event handler.
RulesTestEventHandler::isWatching public function Implements RulesEventDispatcherInterface::isWatching(). Overrides RulesEventDispatcherInterface::isWatching
RulesTestEventHandler::startWatching public function Implements RulesEventDispatcherInterface::startWatching(). Overrides RulesEventDispatcherInterface::startWatching
RulesTestEventHandler::stopWatching public function Implements RulesEventDispatcherInterface::stopWatching(). Overrides RulesEventDispatcherInterface::stopWatching