17 lines
345 B
C
17 lines
345 B
C
#ifndef cmsg_node_h
|
|
#define cmsg_node_h
|
|
|
|
typedef struct node_t_ {
|
|
struct node_class_t_ *node_class;
|
|
cmsg_bytes_t name; /* used as (partial) routing key for metamessages */
|
|
} node_t;
|
|
|
|
typedef struct node_class_t_ {
|
|
void (*destroy)(node_t *n);
|
|
void (*handle_message)(node_t *n, msg_t *m);
|
|
} node_class_t;
|
|
|
|
extern node_t *new_node(
|
|
|
|
#endif
|