]> granicus.if.org Git - icinga2/commitdiff
Updated documentation.
authorGunnar Beutner <gunnar.beutner@netways.de>
Wed, 19 Sep 2012 10:32:39 +0000 (12:32 +0200)
committerGunnar Beutner <gunnar.beutner@netways.de>
Wed, 19 Sep 2012 10:32:39 +0000 (12:32 +0200)
19 files changed:
lib/base/asynctask.h
lib/base/component.h
lib/base/dictionary.cpp
lib/base/dictionary.h
lib/base/dynamicobject.h
lib/base/exception.h
lib/base/netstring.h
lib/base/object.h
lib/config/configcompiler.cpp
lib/config/configcompiler.h
lib/config/configitem.cpp
lib/config/configitem.h
lib/config/configitembuilder.cpp
lib/config/configitembuilder.h
lib/config/debuginfo.h
lib/config/expression.cpp
lib/config/expression.h
lib/config/expressionlist.cpp
lib/config/i2-config.h

index 66d438be30eb6d42714d4a1fa89be4edab5d0c03..e05c1c343911e48a658cd4227f8d7acef60bbe0e 100644 (file)
@@ -35,6 +35,9 @@ public:
        typedef shared_ptr<AsyncTask<TClass, TResult> > Ptr;
        typedef weak_ptr<AsyncTask<TClass, TResult> > WeakPtr;
 
+       /**
+        * A completion callback for an AsyncTask.
+        */
        typedef function<void (const shared_ptr<TClass>&)> CompletionCallback;
 
        /**
index d87335f4bc8aeb4ddae0ed65be840637dc3178ff..f1c92bf228eb62fe37a2596d258d454f099a59ca 100644 (file)
@@ -41,7 +41,8 @@ protected:
        DynamicObject::Ptr GetConfig(void) const;
 
 private:
-       DynamicObject *m_Config;
+       DynamicObject *m_Config; /**< The configuration object for this
+                                     component. */
 
        friend class Component;
 };
@@ -64,7 +65,8 @@ public:
        static void AddSearchDir(const String& componentDirectory);
 
 private:
-       IComponent::Ptr m_Impl;
+       IComponent::Ptr m_Impl; /**< The implementation object for this
+                                    component. */
 };
 
 typedef IComponent *(*CreateComponentFunction)(void);
index 7bf487028481b149e9d2b5900cb70503b730cfca..9306b3fbc92fef6af363f20970a2b06cd94ab4f4 100644 (file)
 using namespace icinga;
 
 /**
- * Compares the keys of dictionary keys using the less operator.
+ * Compares dictionary keys using the less operator.
  */
 struct DictionaryKeyLessComparer
 {
+       /**
+        * Compares two keys.
+        *
+        * @param a The first key.
+        * @param b The second key.
+        * @returns true if the first key is less than the second key, false
+        *               otherwise
+        */
        bool operator()(const pair<String, Value>& a, const char *b)
        {
                return a.first < b;
        }
 
+       /**
+        * Compares two keys.
+        *
+        * @param a The first key.
+        * @param b The second key.
+        * @returns true if the first key is less than the second key, false
+        *               otherwise
+        */
        bool operator()(const char *a, const pair<String, Value>& b)
        {
                return a < b.first;
index 43dbc61c9f1d4703d932c01e5e52a6476172b06e..fc5065eee7d9acccd814f807bc99f08539d083cf 100644 (file)
@@ -34,6 +34,9 @@ public:
        typedef shared_ptr<Dictionary> Ptr;
        typedef weak_ptr<Dictionary> WeakPtr;
 
+       /**
+        * An iterator that can be used to iterate over dictionary elements.
+        */
        typedef map<String, Value>::iterator Iterator;
 
        Value Get(const char *key) const;
@@ -56,7 +59,7 @@ public:
        cJSON *ToJson(void) const;
 
 private:
-       map<String, Value> m_Data;
+       map<String, Value> m_Data; /**< The data for the dictionary. */
 };
 
 inline Dictionary::Iterator range_begin(Dictionary::Ptr x)
index e2e46526312e40c4096c46cd64a9dcbdeb72eea4..3642105294ee0905253141d601e9e0eb6ab3d341 100644 (file)
@@ -25,6 +25,8 @@ namespace icinga
 
 /**
  * The type of an attribute for a DynamicObject.
+ *
+ * @ingroup base
  */
 enum DynamicAttributeType
 {
@@ -48,6 +50,8 @@ enum DynamicAttributeType
 
 /**
  * An attribute for a DynamicObject.
+ *
+ * @ingroup base
  */
 struct DynamicAttribute
 {
@@ -166,6 +170,11 @@ public:
        }
 };
 
+/**
+ * Factory function for DynamicObject-based classes.
+ *
+ * @ingroup base
+ */
 template<typename T>
 shared_ptr<T> DynamicObjectFactory(const Dictionary::Ptr& serializedUpdate)
 {
index 1e5bd19c50fde93176f2c31fd705c2f702924952..b4ead45a8e45daa1c958ca11cbdcc35509c7f7c4 100644 (file)
@@ -86,6 +86,8 @@ DEFINE_EXCEPTION_CLASS(NotImplementedException);
 #ifdef _WIN32
 /**
  * A Win32 error encapsulated in an exception.
+ *
+ * @ingroup base
  */
 class Win32Exception : public Exception
 {
@@ -112,6 +114,8 @@ public:
 
 /**
  * A Posix error encapsulated in an exception.
+ *
+ * @ingroup base
  */
 class PosixException : public Exception
 {
@@ -137,6 +141,8 @@ public:
 
 /**
  * An OpenSSL error encapsulated in an exception.
+ *
+ * @ingroup base
  */
 class OpenSSLException : public Exception
 {
index 3688ae33c28011dfbf9d5a518b549087ab563759..d32616e4c9cffc1663bc958cb899bfff4651c791 100644 (file)
@@ -24,9 +24,9 @@ namespace icinga
 {
 
 /**
- * Helper functions for reading/writing messages in the netString format.
+ * Helper functions for reading/writing messages in the netstring format.
  *
- * @see http://cr.yp.to/proto/netStrings.txt
+ * @see http://cr.yp.to/proto/netstrings.txt
  *
  * @ingroup base
  */
index c58a877cf5301ceef7b16206372421a7807aea78..038819ac7a2a173c2d2e4c442453f0431715afd9 100644 (file)
@@ -42,14 +42,28 @@ public:
 
        /**
         * Holds a shared pointer and provides support for implicit upcasts.
+        *
+        * @ingroup base
         */
        class SharedPtrHolder
        {
        public:
+               /**
+                * Constructor for the SharedPtrHolder class.
+                *
+                * @param object The shared pointer that should be used to
+                *               construct this shared pointer holder.
+                */
                explicit SharedPtrHolder(const Object::Ptr& object)
                        : m_Object(object)
                { }
 
+               /**
+                * Retrieves a shared pointer for the object that is associated
+                * this holder instance.
+                *
+                * @returns A shared pointer.
+                */
                template<typename T>
                operator shared_ptr<T>(void) const
                {
@@ -63,6 +77,12 @@ public:
                        return other;
                }
 
+               /**
+                * Retrieves a weak pointer for the object that is associated
+                * with this holder instance.
+                *
+                * @returns A weak pointer.
+                */
                template<typename T>
                operator weak_ptr<T>(void) const
                {
@@ -70,7 +90,8 @@ public:
                }
 
        private:
-               Object::Ptr m_Object;
+               Object::Ptr m_Object; /**< The object that belongs to this
+                                          holder instance */
        };
 
        SharedPtrHolder GetSelf(void);
@@ -88,23 +109,33 @@ private:
        Object(const Object& other);
        Object& operator=(const Object& rhs);
 
-       static boost::mutex m_Mutex;
-       static vector<Object::Ptr> m_HeldObjects;
+       static boost::mutex m_Mutex; /**< Mutex which protects static members
+                                         of the Object class. */
+       static vector<Object::Ptr> m_HeldObjects; /**< Currently held
+                                                      objects. */
 #ifdef _DEBUG
-       static set<Object *> m_AliveObjects;
+       static set<Object *> m_AliveObjects; /**< Currently alive objects -
+                                                 for debugging purposes. */
 #endif /* _DEBUG */
 };
 
 /**
  * Compares a weak pointer with a raw pointer.
+ *
+ * @ingroup base
  */
 template<class T>
 struct WeakPtrEqual
 {
 private:
-       const void *m_Ref;
+       const void *m_Ref; /**< The object. */
 
 public:
+       /**
+        * Constructor for the WeakPtrEqual class.
+        *
+        * @param ref The object that should be compared with the weak pointer.
+        */
        WeakPtrEqual(const void *ref) : m_Ref(ref) { }
 
        /**
index bf80ce0be5d33bd3ab8aeac66c3310586ec99694..386a92012d3d8cf43ecda7e8898f2193ad8cc00d 100644 (file)
@@ -23,38 +23,78 @@ using std::ifstream;
 
 using namespace icinga;
 
-ConfigCompiler::ConfigCompiler(const String& path, istream *input, HandleIncludeFunc includeHandler)
+/**
+ * Constructor for the ConfigCompiler class.
+ *
+ * @param path The path of the configuration file (or another name that
+ *            identifies the source of the configuration text).
+ * @param input Input stream for the configuration file.
+ * @param includeHandler Handler function for #include directives.
+ */
+ConfigCompiler::ConfigCompiler(const String& path, istream *input,
+    HandleIncludeFunc includeHandler)
        : m_Path(path), m_Input(input), m_HandleInclude(includeHandler)
 {
        InitializeScanner();
 }
 
+/**
+ * Destructor for the ConfigCompiler class.
+ */
 ConfigCompiler::~ConfigCompiler(void)
 {
        DestroyScanner();
 }
 
+/**
+ * Reads data from the input stream. Used internally by the lexer.
+ *
+ * @param buffer Where to store data.
+ * @param max_size The maximum number of bytes to read from the stream.
+ * @returns The actual number of bytes read.
+ */
 size_t ConfigCompiler::ReadInput(char *buffer, size_t max_size)
 {
        m_Input->read(buffer, max_size);
        return static_cast<size_t>(m_Input->gcount());
 }
 
+/**
+ * Retrieves the scanner object.
+ *
+ * @returns The scanner object.
+ */
 void *ConfigCompiler::GetScanner(void) const
 {
        return m_Scanner;
 }
 
+/**
+ * Retrieves the result from the compiler.
+ *
+ * @returns A list of configuration items.
+ */
 vector<ConfigItem::Ptr> ConfigCompiler::GetResult(void) const
 {
        return m_Result;
 }
 
+/**
+ * Retrieves the path for the input file.
+ *
+ * @returns The path.
+ */
 String ConfigCompiler::GetPath(void) const
 {
        return m_Path;
 }
 
+/**
+ * Handles an include directive by calling the include handler callback
+ * function.
+ *
+ * @param include The path from the include directive.
+ */
 void ConfigCompiler::HandleInclude(const String& include)
 {
        String path = Utility::DirName(GetPath()) + "/" + include;
@@ -62,13 +102,27 @@ void ConfigCompiler::HandleInclude(const String& include)
        std::copy(items.begin(), items.end(), back_inserter(m_Result));
 }
 
-vector<ConfigItem::Ptr> ConfigCompiler::CompileStream(const String& path, istream *stream)
+/**
+ * Compiles a stream.
+ *
+ * @param path A name identifying the stream.
+ * @param stream The input stream.
+ * @returns Configuration items.
+ */
+vector<ConfigItem::Ptr> ConfigCompiler::CompileStream(const String& path,
+    istream *stream)
 {
        ConfigCompiler ctx(path, stream);
        ctx.Compile();
        return ctx.GetResult();
 }
 
+/**
+ * Compiles a file.
+ *
+ * @param path The path.
+ * @returns Configuration items.
+ */
 vector<ConfigItem::Ptr> ConfigCompiler::CompileFile(const String& path)
 {
        ifstream stream;
@@ -82,18 +136,39 @@ vector<ConfigItem::Ptr> ConfigCompiler::CompileFile(const String& path)
        return CompileStream(path, &stream);
 }
 
-vector<ConfigItem::Ptr> ConfigCompiler::CompileText(const String& path, const String& text)
+/**
+ * Compiles a snippet of text.
+ *
+ * @param path A name identifying the text.
+ * @param text The text.
+ * @returns Configuration items.
+ */
+vector<ConfigItem::Ptr> ConfigCompiler::CompileText(const String& path,
+    const String& text)
 {
        stringstream stream(text);
        return CompileStream(path, &stream);
 }
 
+/**
+ * Default include handler. Includes the file and returns a list of
+ * configuration items.
+ *
+ * @param include The path from the include directive.
+ * @returns A list of configuration objects.
+ */
 vector<ConfigItem::Ptr> ConfigCompiler::HandleFileInclude(const String& include)
 {
        /* TODO: implement wildcard includes */
        return CompileFile(include);
 }
 
+/**
+ * Adds an object to the result.
+ *
+ * @param object The configuration item.
+ */
+ * 
 void ConfigCompiler::AddObject(const ConfigItem::Ptr& object)
 {
        m_Result.push_back(object);
index ef4c572a947ad049a5630283e9212759b42ec55b..d214e446e6e2216fbe5615617a1208fb3fa255c5 100644 (file)
@@ -25,7 +25,7 @@ namespace icinga
 
 /**
  * The configuration compiler can be used to compile a configuration file
- * into a number of configuration objects.
+ * into a number of configuration items.
  *
  * @ingroup config
  */
@@ -40,9 +40,11 @@ public:
 
        void Compile(void);
 
-       static vector<ConfigItem::Ptr> CompileStream(const String& path, istream *stream);
+       static vector<ConfigItem::Ptr> CompileStream(const String& path,
+           istream *stream);
        static vector<ConfigItem::Ptr> CompileFile(const String& path);
-       static vector<ConfigItem::Ptr> CompileText(const String& path, const String& text);
+       static vector<ConfigItem::Ptr> CompileText(const String& path,
+           const String& text);
 
        static vector<ConfigItem::Ptr> HandleFileInclude(const String& include);
 
index ff57bf966883a4020f60a4170ac7e460ec78a0ab..927ef341dff6eb6a2c3804b0514837fb9101cfc4 100644 (file)
@@ -25,6 +25,15 @@ ConfigItem::ItemMap ConfigItem::m_Items;
 boost::signal<void (const ConfigItem::Ptr&)> ConfigItem::OnCommitted;
 boost::signal<void (const ConfigItem::Ptr&)> ConfigItem::OnRemoved;
 
+/**
+ * Constructor for the ConfigItem class.
+ *
+ * @param type The object type.
+ * @param name The name of the item.
+ * @param exprl Expression list for the item.
+ * @param parents Parent objects for the item.
+ * @param debuginfo Debug information.
+ */
 ConfigItem::ConfigItem(const String& type, const String& name,
     const ExpressionList::Ptr& exprl, const vector<String>& parents,
     const DebugInfo& debuginfo)
@@ -33,31 +42,63 @@ ConfigItem::ConfigItem(const String& type, const String& name,
 {
 }
 
+/**
+ * Retrieves the type of the configuration item.
+ *
+ * @returns The type.
+ */
 String ConfigItem::GetType(void) const
 {
        return m_Type;
 }
 
+/**
+ * Retrieves the name of the configuration item.
+ *
+ * @returns The name.
+ */
 String ConfigItem::GetName(void) const
 {
        return m_Name;
 }
 
+/**
+ * Retrieves the debug information for the configuration item.
+ *
+ * @returns The debug information.
+ */
 DebugInfo ConfigItem::GetDebugInfo(void) const
 {
        return m_DebugInfo;
 }
 
+/**
+ * Retrieves the expression list for the configuration item.
+ *
+ * @returns The expression list.
+ */
 ExpressionList::Ptr ConfigItem::GetExpressionList(void) const
 {
        return m_ExpressionList;
 }
 
+/**
+ * Retrieves the list of parents for the configuration item.
+ *
+ * @returns The list of parents.
+ */
 vector<String> ConfigItem::GetParents(void) const
 {
        return m_Parents;
 }
 
+/**
+ * Calculates the object's properties based on parent objects and the object's
+ * expression list.
+ *
+ * @param dictionary The dictionary that should be used to store the
+ *                  properties.
+ */
 void ConfigItem::CalculateProperties(const Dictionary::Ptr& dictionary) const
 {
        BOOST_FOREACH(const String& name, m_Parents) {
@@ -65,7 +106,8 @@ void ConfigItem::CalculateProperties(const Dictionary::Ptr& dictionary) const
 
                if (!parent) {
                        stringstream message;
-                       message << "Parent object '" << name << "' does not exist (" << m_DebugInfo << ")";
+                       message << "Parent object '" << name << "' does not"
+                           " exist (" << m_DebugInfo << ")";
                        throw_exception(domain_error(message.str()));
                }
 
@@ -75,6 +117,12 @@ void ConfigItem::CalculateProperties(const Dictionary::Ptr& dictionary) const
        m_ExpressionList->Execute(dictionary);
 }
 
+/**
+ * Commits the configuration item by creating or updating a DynamicObject
+ * object.
+ *
+ * @returns The DynamicObject that was created/updated.
+ */
 DynamicObject::Ptr ConfigItem::Commit(void)
 {
        DynamicObject::Ptr dobj = m_DynamicObject.lock();
@@ -125,6 +173,9 @@ DynamicObject::Ptr ConfigItem::Commit(void)
        return dobj;
 }
 
+/**
+ * Unregisters the configuration item.
+ */
 void ConfigItem::Unregister(void)
 {
        DynamicObject::Ptr dobj = m_DynamicObject.lock();
@@ -141,11 +192,23 @@ void ConfigItem::Unregister(void)
        OnRemoved(GetSelf());
 }
 
+/**
+ * Retrieves the DynamicObject that belongs to the configuration item.
+ *
+ * @returns The DynamicObject.
+ */
 DynamicObject::Ptr ConfigItem::GetDynamicObject(void) const
 {
        return m_DynamicObject.lock();
 }
 
+/**
+ * Retrieves a configuration item by type and name.
+ *
+ * @param type The type of the ConfigItem that is to be looked up.
+ * @param name The name of the ConfigItem that is to be looked up.
+ * @returns The configuration item.
+ */
 ConfigItem::Ptr ConfigItem::GetObject(const String& type, const String& name)
 {
        ConfigItem::ItemMap::iterator it;
index 0c1307dca9009167aec0c9deeda2ed0feea55c42..8bce294934a0291be8e33be3af5bf02a5e3e7913 100644 (file)
@@ -24,8 +24,8 @@ namespace icinga
 {
 
 /**
- * A configuration item. Can be used to create a configuration object at
- * runtime.
+ * A configuration item. Non-abstract configuration items can be used to
+ * create configuration objects at runtime.
  *
  * @ingroup config
  */
@@ -52,7 +52,8 @@ public:
 
        DebugInfo GetDebugInfo(void) const;
 
-       static ConfigItem::Ptr GetObject(const String& type, const String& name);
+       static ConfigItem::Ptr GetObject(const String& type,
+           const String& name);
 
        static boost::signal<void (const ConfigItem::Ptr&)> OnCommitted;
        static boost::signal<void (const ConfigItem::Ptr&)> OnRemoved;
@@ -60,17 +61,20 @@ public:
 private:
        void CalculateProperties(const Dictionary::Ptr& dictionary) const;
 
-       String m_Type;
-       String m_Name;
+       String m_Type; /**< The object type. */
+       String m_Name; /**< The name. */
 
        ExpressionList::Ptr m_ExpressionList;
-       vector<String> m_Parents;
-       DebugInfo m_DebugInfo;
+       vector<String> m_Parents; /**< The names of parent configuration
+                                      items. */
+       DebugInfo m_DebugInfo; /**< Debug information. */
 
-       DynamicObject::WeakPtr m_DynamicObject;
+       DynamicObject::WeakPtr m_DynamicObject; /**< The instantiated version
+                                                    of this configuration
+                                                    item */
 
        typedef map<pair<String, String>, ConfigItem::Ptr> ItemMap;
-       static ItemMap m_Items;
+       static ItemMap m_Items; /**< All registered configuration items. */
 };
 
 }
index 36e3671b0aa6e37b737ef9b08c008da976e5f599..70963bcec9e63f2f552c184786c5ddb870e8978b 100644 (file)
@@ -68,7 +68,8 @@ void ConfigItemBuilder::AddExpression(const Expression& expr)
        m_ExpressionList->AddExpression(expr);
 }
 
-void ConfigItemBuilder::AddExpression(const String& key, ExpressionOperator op, const Value& value)
+void ConfigItemBuilder::AddExpression(const String& key, ExpressionOperator op,
+    const Value& value)
 {
        Expression expr(key, op, value, m_DebugInfo);
        AddExpression(expr);
@@ -101,5 +102,6 @@ ConfigItem::Ptr ConfigItemBuilder::Compile(void)
        Expression abstractExpr("__abstract", OperatorSet, m_Abstract, m_DebugInfo);
        exprl->AddExpression(abstractExpr);
 
-       return boost::make_shared<ConfigItem>(m_Type, m_Name, exprl, m_Parents, m_DebugInfo);
+       return boost::make_shared<ConfigItem>(m_Type, m_Name, exprl, m_Parents,
+           m_DebugInfo);
 }
index 9bd887b60fd097615df8d3654d536049a30ffe3e..a857c3f112438a16e80c86fcf4dac7ff71a59e53 100644 (file)
@@ -46,19 +46,21 @@ public:
        void AddParent(const String& parent);
 
        void AddExpression(const Expression& expr);
-       void AddExpression(const String& key, ExpressionOperator op, const Value& value);
+       void AddExpression(const String& key, ExpressionOperator op,
+           const Value& value);
        void AddExpressionList(const ExpressionList::Ptr& exprl);
 
        ConfigItem::Ptr Compile(void);
 
 private:
-       String m_Type;
-       String m_Name;
-       bool m_Local;
-       bool m_Abstract;
-       vector<String> m_Parents;
-       ExpressionList::Ptr m_ExpressionList;
-       DebugInfo m_DebugInfo;
+       String m_Type; /**< The object type. */
+       String m_Name; /**< The name. */
+       bool m_Local; /**< Whether the item is local. */
+       bool m_Abstract; /**< Whether the item is abstract. */
+       vector<String> m_Parents; /**< The names of parent configuration
+                                      items. */
+       ExpressionList::Ptr m_ExpressionList; /**< Expressions for this item. */
+       DebugInfo m_DebugInfo; /**< Debug information. */
 };
 
 }
index 984c378aac661a88c7a25b5e0ea939af67cc89f2..7918f70addf8b57ec63dcb4052a4be5ee5f69b9e 100644 (file)
@@ -57,6 +57,13 @@ struct DebugInfo
        };
 };
 
+/**
+ * Outputs a DebugInfo struct to a stream.
+ *
+ * @param out The output stream.
+ * @param val The DebugInfo struct.
+ * @returns The output stream.
+ */
 inline ostream& operator<<(ostream& out, const DebugInfo& val)
 {
        out << "in " << val.Path << ": "
index 66b37e2ab073245e9e290e16f5a3301059f3abf0..fe88d2536712ec6ad48bdf90b851b6d08032c489 100644 (file)
@@ -21,7 +21,8 @@
 
 using namespace icinga;
 
-Expression::Expression(const String& key, ExpressionOperator op, const Value& value, const DebugInfo& debuginfo)
+Expression::Expression(const String& key, ExpressionOperator op,
+    const Value& value, const DebugInfo& debuginfo)
        : m_Key(key), m_Operator(op), m_Value(value), m_DebugInfo(debuginfo)
 {
 }
@@ -69,7 +70,10 @@ void Expression::Execute(const Dictionary::Ptr& dictionary) const
                        if (!dict) {
                                if (!oldValue.IsEmpty()) {
                                        stringstream message;
-                                       message << "Wrong argument types for += (non-dictionary and dictionary) (" << m_DebugInfo << ")";
+                                       message << "Wrong argument types for"
+                                           " += (non-dictionary and"
+                                           " dictionary) ("
+                                               << m_DebugInfo << ")";
                                        throw_exception(domain_error(message.str()));
                                }
 
@@ -88,7 +92,8 @@ void Expression::Execute(const Dictionary::Ptr& dictionary) const
                                }
                        } else {
                                stringstream message;
-                               message << "+= only works for dictionaries (" << m_DebugInfo << ")";
+                               message << "+= only works for dictionaries ("
+                                       << m_DebugInfo << ")";
                                throw_exception(domain_error(message.str()));
                        }
 
index 533b0979f35bf76997f2a2b5286eb329adb8a60d..378f1c94bd07725895d2f5bda3fa68d0823e429e 100644 (file)
@@ -46,7 +46,8 @@ enum ExpressionOperator
 struct I2_CONFIG_API Expression
 {
 public:
-       Expression(const String& key, ExpressionOperator op, const Value& value, const DebugInfo& debuginfo);
+       Expression(const String& key, ExpressionOperator op, const Value& value,
+           const DebugInfo& debuginfo);
 
        void Execute(const Dictionary::Ptr& dictionary) const;
 
index a22be1d61611dcfc34120144e1d7b423e2bb147f..54782f130a925684cf1829102a4a041462c78b1c 100644 (file)
 
 using namespace icinga;
 
+/**
+ * Adds an expression to an expression list.
+ *
+ * @param expression The expression that should be added.
+ */
 void ExpressionList::AddExpression(const Expression& expression)
 {
        m_Expressions.push_back(expression);
 }
 
+/**
+ * Returns the number of items currently contained in the expression list.
+ *
+ * @returns The length of the list.
+ */
 size_t ExpressionList::GetLength(void) const
 {
        return m_Expressions.size();
 }
 
+/**
+ * Executes the expression list.
+ *
+ * @param dictionary The dictionary that should be manipulated by the
+ *                  expressions.
+ */
 void ExpressionList::Execute(const Dictionary::Ptr& dictionary) const
 {
        BOOST_FOREACH(const Expression& expression, m_Expressions) {
index 868b7e66e4d152c271435cbe1fff6da1721514c2..c378e182d4e082872e7af0f28ad71c7dc144ba0a 100644 (file)
@@ -24,7 +24,7 @@
  * @defgroup config Configuration library
  *
  * The configuration library implements a compiler for Icinga 2's configuration
- * format. It also provides functionality to create configuration objects
+ * format. It also provides functionality for creating configuration objects
  * at runtime.
  */