Simple config file class with added support for floats

Fork of ConfigFile by peter brier

Revision:
2:ba316099c799
Parent:
1:a802df951169
Child:
3:31c936f3b9df
--- a/ConfigFile.h	Thu Jan 27 21:23:19 2011 +0000
+++ b/ConfigFile.h	Thu Jan 27 21:36:01 2011 +0000
@@ -1,4 +1,4 @@
-/*
+/**
  * ConfigFile.cpp
  * Simple Config file reader class
  *
@@ -38,18 +38,24 @@
 #define _CONFIG_FILE_H_
 
     /** Simple config file object
+      * Only supports reading config files. Tries to limit memory usage.
       * Note: the file handle is kept open during the lifetime of this object.
       * To close the file: destroy this ConfigFile object! A simple way is to enclose the creation
       * of this object inside a code block
       * Example:
       * @code 
-      *  bla
+      * char ip[16];
+      * int port;
+      * {
+      *   ConfigFile cfg("/local/config.txt");
+      *   cfg.Value("ip", val, sizeof(val), "192.168.1.10");
+      *   cfg.Value("port", &port, 80);
+      * }
       * @endcode
       */
 class ConfigFile {
 public:
-    /// Make new config file object
-    /** Open config file.
+    /** Make new ConfigFile object. Open config file.
       * Note: the file handle is kept open during the lifetime of this object.
       * To close the file: destroy this ConfigFile object!
       * @param file Filename of the configuration file.