1 // URL_Array_Helper.cpp
3 #ifndef ACE_URL_ARRAY_HELPER_C
4 #define ACE_URL_ARRAY_HELPER_C
6 #include "URL_Array_Helper.h"
8 // Some helper functions for encoding/decoding
11 size_t ace_array_size (const T
&x
)
13 size_t sum
= sizeof (ACE_UINT32
);
14 for (size_t i
= 0; i
< x
.size (); i
++)
20 size_t ace_array_encode (void *buf
, const T
&x
)
23 for (size_t i
= 0; i
< x
.size (); i
++)
24 len
+= x
[i
].encode ((void *) ((char *) buf
+ len
));
29 size_t ace_array_decode (void *buf
, T
&x
)
32 for (size_t i
= 0; i
< x
.size (); i
++)
33 len
+= x
[i
].decode ((void *) ((char *) buf
+ len
));
38 #endif /* ACE_URL_ARRAY_HELPER_C */