|
@@ -24,27 +24,27 @@ |
|
@@ -24,27 +24,27 @@ |
24
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
24
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
25
|
*/
|
25
|
*/
|
26
|
|
26
|
|
27
|
-#ifndef __SERIALIZABLE_H__
|
|
|
28
|
-#define __SERIALIZABLE_H__
|
27
|
+#ifndef __TR_SERIALIZABLE_H__
|
|
|
28
|
+#define __TR_SERIALIZABLE_H__
|
29
|
|
29
|
|
30
|
#include "tr/interface.h"
|
30
|
#include "tr/interface.h"
|
31
|
|
31
|
|
32
|
|
32
|
|
33
|
-typedef size_t (* fptr_serializeSize)(void *);
|
|
|
34
|
-typedef void (* fptr_serialize)(void *, unsigned char *);
|
33
|
+//typedef size_t (* fptr_serializeSize)(void *);
|
|
|
34
|
+typedef void (* fptr_serialize)(void *, unsigned char **, size_t *);
|
35
|
typedef void (* fptr_unserialize)(void *, const unsigned char *, size_t);
|
35
|
typedef void (* fptr_unserialize)(void *, const unsigned char *, size_t);
|
36
|
|
36
|
|
37
|
TR_INTERFACE(TR_Serializable) {
|
37
|
TR_INTERFACE(TR_Serializable) {
|
38
|
TR_IFID;
|
38
|
TR_IFID;
|
39
|
- fptr_serializeSize serializeSize;
|
39
|
+// fptr_serializeSize serializeSize;
|
40
|
fptr_serialize serialize;
|
40
|
fptr_serialize serialize;
|
41
|
fptr_unserialize unserialize;
|
41
|
fptr_unserialize unserialize;
|
42
|
};
|
42
|
};
|
43
|
|
43
|
|
44
|
-size_t TR_serializeSize(void *);
|
|
|
45
|
-void TR_serialize(void *, unsigned char *);
|
44
|
+//size_t TR_serializeSize(void *);
|
|
|
45
|
+void TR_serialize(void *, unsigned char **, size_t *);
|
46
|
void TR_unserialize(void *, const unsigned char *, size_t);
|
46
|
void TR_unserialize(void *, const unsigned char *, size_t);
|
47
|
|
47
|
|
48
|
-#endif // __SERIALIZABLE_H__
|
48
|
+#endif // __TR_SERIALIZABLE_H__
|
49
|
|
49
|
|
50
|
// vim: set ts=4 sw=4: |
50
|
// vim: set ts=4 sw=4: |