first cut of Object Notification API and tests
[cilux] / src / include / ni.h
index 32c90b2..7916190 100644 (file)
@@ -4,6 +4,22 @@
 
 /* -------------------------------------------------------------------------- */
 
+typedef struct n_object{
+       k_hashtable* headers;
+       k_hashtable* content;
+} n_object;
+
+PUBLIC n_object*    n_object_new(char* s);
+PUBLIC void         n_commit(n_object* o);
+PUBLIC n_object*    n_see(n_object* o, char* uid);
+PUBLIC char*        n_to_string(n_object* o);
+PUBLIC char*        n_uid(n_object* o);
+PUBLIC char*        n_header(n_object* o, char* name);
+PUBLIC k_hashtable* n_headers(n_object* o);
+PUBLIC k_hashtable* n_content(n_object* o);
+
+/* -------------------------------------------------------------------------- */
+
 PUBLIC char* ni_hostname(void);
 PUBLIC void  ni_hostname_set(char* name);
 
@@ -66,7 +82,7 @@ PUBLIC void      ni_response(ni_event* evt,
                              char*      protocol,
                              char*      connection,
                              k_channel* chan);
-EXPORT void      ni_request(ni_event* evt,
+PUBLIC void      ni_request(ni_event* evt,
                             char*      to,
                             char*      method,
                             k_channel* chan);