OSSP CVS Repository

ossp - Check-in [4129]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 4129
Date: 2001-Jun-28 17:25:23 (local)
2001-Jun-28 15:25:23 (UTC)
User:simons
Branch:
Comment: The API after the seconds review with RSE.
Tickets:
Inspections:
Files:
ossp-pkg/xds/xds.h      1.3 -> 1.4     12 inserted, 18 deleted

ossp-pkg/xds/xds.h 1.3 -> 1.4

--- xds.h        2001/06/28 14:42:06     1.3
+++ xds.h        2001/06/28 15:25:23     1.4
@@ -1,6 +1,6 @@
 /*
    $Source: /v/ossp/cvs/ossp-pkg/xds/Attic/xds.h,v $
-   $Revision: 1.3 $
+   $Revision: 1.4 $
 
    Copyright (c) 2001 by Cable & Wireless Deutschland.
 
@@ -22,24 +22,12 @@
 #include <stdarg.h>
 
 struct xds_ctx;
+typedef struct xds_ctx xds_ctx_t;
 
-typedef int (*xds_fmt_cb_t)(struct xds_ctx* context,
+typedef int (*xds_fmt_cb_t)(xds_ctx_t* context,
                             void* fmt_context,
                             char* buf, size_t buf_size,
-                            va_list val);
-
-struct fmt_cb
-    {
-    char*          name;
-    xds_fmt_cb_t   callback;
-    void*          fmt_context;
-    };
-
-struct xds_ctx
-    {
-    struct fmt_cb* formatters;
-    };
-typedef struct xds_ctx xds_ctx_t;
+                            va_list args);
 
 xds_ctx_t*  xds_init(void);
 void        xds_destroy(xds_ctx_t* context);
@@ -47,11 +35,17 @@
 int xds_register(xds_ctx_t* context,
                  const char* name, xds_fmt_cb_t callback,
                  void* formatter_context);
+int xds_register_xdr(xds_ctx_t* context);
+int xds_register_xml(xds_ctx_t* context);
+int xds_register_asn1(xds_ctx_t* context);
 int xds_unregister(xds_ctx_t* context, const char* name);
 
-int xds_encode(xds_ctx_t* context, char* buf, size_t buf_size, const char* fmt, ...);
-char* xds_aencode(xds_ctx_t* context, const char* fmt, ...);
+char* xds_get_buffer(xds_ctx_t* context);
+int xds_set_buffer(xds_ctx_t* context, char* buf, size_t buf_size);
 
+int xds_encode(xds_ctx_t* context, const char* fmt, ...);
 int xds_decode(xds_ctx_t* context, const char* buf, const char* fmt, ...);
+int xds_vdecode(xds_ctx_t* context, const char* buf, const char* fmt, va_list args);
+int xds_vencode(xds_ctx_t* context, const char* fmt, va_list args);
 
 #endif /* !defined(__LIBXDS_H__) */

CVSTrac 2.0.1