ucx update
[uwplayer.git] / application / properties.h
similarity index 91%
rename from ucx/ucx/properties.h
rename to application/properties.h
index 819d1e5..cfb4359 100644 (file)
 #ifndef UCX_PROPERTIES_H
 #define        UCX_PROPERTIES_H
 
-#include "ucx.h"
-#include "map.h"
+#include <cx/hash_map.h>
+#include <cx/string.h>
+
+#include <stdio.h>
 
 #ifdef __cplusplus
 extern "C" {
@@ -156,18 +158,18 @@ void ucx_properties_fill(UcxProperties *prop, char *buf, size_t len);
  * found. If no more key/value-pairs are found, you may refill the input buffer
  * with ucx_properties_fill().
  * 
- * <b>Attention:</b> the sstr_t.ptr pointers of the output parameters point to
+ * <b>Attention:</b> the cxstring.ptr pointers of the output parameters point to
  * memory within the input buffer of the parser and will get invalid some time.
  * If you want long term copies of the key/value-pairs, use sstrdup() after
  * calling this function.
  * 
  * @param prop the UcxProperties object
- * @param name a pointer to the sstr_t that shall contain the property name
- * @param value a pointer to the sstr_t that shall contain the property value
+ * @param name a pointer to the cxstring that shall contain the property name
+ * @param value a pointer to the cxstring that shall contain the property value
  * @return Nonzero, if a key/value-pair was successfully retrieved
  * @see ucx_properties_fill()
  */
-int ucx_properties_next(UcxProperties *prop, sstr_t *name, sstr_t *value);
+int ucx_properties_next(UcxProperties *prop, cxstring *name, cxstring *value);
 
 /**
  * Retrieves all available key/value-pairs and puts them into a UcxMap.
@@ -183,7 +185,7 @@ int ucx_properties_next(UcxProperties *prop, sstr_t *name, sstr_t *value);
  * @see ucx_properties_fill()
  * @see UcxMap.allocator
  */
-int ucx_properties2map(UcxProperties *prop, UcxMap *map);
+int ucx_properties2map(UcxProperties *prop, CxMap *map);
 
 /**
  * Loads a properties file to a UcxMap.
@@ -198,7 +200,7 @@ int ucx_properties2map(UcxProperties *prop, UcxMap *map);
  * @see ucx_properties_fill()
  * @see ucx_properties2map()
  */
-int ucx_properties_load(UcxMap *map, FILE *file);
+int ucx_properties_load(CxMap *map, FILE *file);
 
 /**
  * Stores a UcxMap to a file.
@@ -211,7 +213,7 @@ int ucx_properties_load(UcxMap *map, FILE *file);
  * @param file the <code>FILE*</code> stream to write to
  * @return 0 on success, or a non-zero value on error
  */
-int ucx_properties_store(UcxMap *map, FILE *file);
+int ucx_properties_store(CxMap *map, FILE *file);
 
 #ifdef __cplusplus
 }