Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: CDUFinal CDU_Mbed_36
Fork of ConfigFile by
Diff: ConfigFile.h
- Revision:
- 4:940510a29b44
- Parent:
- 3:7250e339328c
- Child:
- 5:56d544b8e5c6
--- a/ConfigFile.h Sun Sep 12 07:37:25 2010 +0000
+++ b/ConfigFile.h Sun Sep 12 07:53:10 2010 +0000
@@ -19,12 +19,12 @@
* Create a configuration file class.
*/
ConfigFile();
-
+
/**
* Destroy a configuration file class.
*/
~ConfigFile();
-
+
/**
* Get a value for a key.
*
@@ -34,7 +34,7 @@
* @return A value or NULL.
*/
bool getValue(char *key, char *value, size_t siz);
-
+
/**
* Set a set of a key and value.
*
@@ -44,7 +44,7 @@
* @return True if it succeed.
*/
bool setValue(char *key, char *value);
-
+
/**
* Remove a config.
*
@@ -53,35 +53,36 @@
* @return True if it succeed.
*/
bool remove(char *key);
-
+
/**
* Remove all config.
*
* @return True if it succeed.
*/
bool removeAll(void);
-
+
/**
* Read from the target file.
*
* @param file A target file name.
*/
bool read(char *file);
-
+
typedef enum {
UNIX,
MAC,
DOS
} FileFormat;
-
+
/**
* Write from the target file.
*
- * @param file A target file name.
+ * @param file A pointer to a file name.
+ * @param header A pointer to a header.
* @param ff File format.
*/
- bool write(char *file, FileFormat ff = UNIX);
-
+ bool write(char *file, char *header = NULL, FileFormat ff = UNIX);
+
/**
* Output for debugging.
*
