conf::ConfRules::ConfRule Class Reference

Rule configuration directive. More...

#include <directives.h>

Inheritance diagram for conf::ConfRules::ConfRule:

conf::ConfDir

List of all members.

Public Member Functions

 ConfRule (std::string const &name, bool reloadable, ConfRules::container_type &container, int type)
 Constructor.
 ConfRule (ConfRule const &cd)
 Copy constructor.
virtual ConfRuleoperator= (ConfRule const &right)
 Assignment operator.
virtual bool set (Conf &conf, unsigned short count, std::string const params[])
 Creates a new rule and adds it to the list.
ConfRules::container_type * container () const
 Returns the container.
ConfRules::container_type * container (ConfRules::container_type &c)
 Sets the container.

Protected Member Functions

virtual bool check (std::string const &value) const
 Checks whether a value is correct.

Protected Attributes

ConfRules::container_type * m_container
 The container to which new rules are added.
int m_type
 The type of created rules.


Detailed Description

This class implements a rule configuration directive, that may be used to the ConfRules block directive. The check() function may be overriden to ensure the value is correct.

Constructor & Destructor Documentation

conf::ConfRules::ConfRule::ConfRule ( std::string const &  name,
bool  reloadable,
ConfRules::container_type &  container,
int  type 
) [inline]

Constructor.

Parameters:
[in] name The directive name.
[in] reloadable Determines whether the directive is reloadable or not.
[in] container The container to which new rules are added by this directive (must be valid until the directive is destroyed).
[in] type The type of rule this directive creates.


Member Function Documentation

virtual bool conf::ConfRules::ConfRule::check ( std::string const &  value  )  const [inline, protected, virtual]

Checks whether a value is correct. This is called automatically by the set() function.

Parameters:
[in] value The value to check.
Returns:
true if the value is correct, false otherwise (which will make set() return false too).
See also:
set()


The documentation for this class was generated from the following file:
Generated on Fri Apr 18 22:03:28 2008 for Epona API by  doxygen 1.5.3