BcPOC
SF-HRP ASM implementation
Public Types | Public Member Functions | Protected Attributes
BaseRule Class Reference

#include <base_rule.hpp>

Inheritance diagram for BaseRule:
IReleaseable ActionRule PlanRule SFRule

List of all members.

Public Types

enum  RuleFlags { NO_FLAGS = 0, INTERRUPT_SAFE = 1, RELEASER_SAFE = 2, STICKY = 4 }

Public Member Functions

 BaseRule (ptrSimplePlan, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int)
virtual void Activate ()
virtual void Deactivate ()
virtual int GetAction ()=0
bool CheckFlags (RuleFlags)
unsigned int GetPriority () const
unsigned int GetWeight () const
void out ()

Protected Attributes

ptrSimplePlan _parent_plan
unsigned int _priority
unsigned int _weight
unsigned int _flags
unsigned int _sticky_timeout
unsigned int _fails
unsigned int _successes
unsigned int _fails_act
unsigned int _successes_act

Member Enumeration Documentation

Enumerator:
NO_FLAGS 
INTERRUPT_SAFE 
RELEASER_SAFE 
STICKY 

Constructor & Destructor Documentation

BaseRule::BaseRule ( ptrSimplePlan  pp,
unsigned int  prio,
unsigned int  weight,
unsigned int  flags,
unsigned int  stt,
unsigned int  fails,
unsigned int  successes 
)

Member Function Documentation

void BaseRule::Activate ( ) [virtual]

Condition changed value to true

Implements IReleaseable.

bool BaseRule::CheckFlags ( RuleFlags  flags)
void BaseRule::Deactivate ( ) [virtual]

Condition changed value tu false

Implements IReleaseable.

virtual int BaseRule::GetAction ( ) [pure virtual]

Implemented in ActionRule, PlanRule, and SFRule.

unsigned int BaseRule::GetPriority ( ) const
unsigned int BaseRule::GetWeight ( ) const
void BaseRule::out ( ) [inline]

Member Data Documentation

unsigned int BaseRule::_fails [protected]
unsigned int BaseRule::_fails_act [protected]
unsigned int BaseRule::_flags [protected]
unsigned int BaseRule::_priority [protected]
unsigned int BaseRule::_sticky_timeout [protected]
unsigned int BaseRule::_successes [protected]
unsigned int BaseRule::_successes_act [protected]
unsigned int BaseRule::_weight [protected]

The documentation for this class was generated from the following files: