2007-04-17 07:03:15 +08:00
|
|
|
#ifndef DECORATE_H
|
|
|
|
#define DECORATE_H
|
|
|
|
|
|
|
|
struct object_decoration {
|
2008-08-21 01:55:33 +08:00
|
|
|
const struct object *base;
|
2007-04-17 07:03:15 +08:00
|
|
|
void *decoration;
|
|
|
|
};
|
|
|
|
|
|
|
|
struct decoration {
|
|
|
|
const char *name;
|
|
|
|
unsigned int size, nr;
|
|
|
|
struct object_decoration *hash;
|
|
|
|
};
|
|
|
|
|
2008-08-21 01:55:33 +08:00
|
|
|
extern void *add_decoration(struct decoration *n, const struct object *obj, void *decoration);
|
|
|
|
extern void *lookup_decoration(struct decoration *n, const struct object *obj);
|
2007-04-17 07:03:15 +08:00
|
|
|
|
|
|
|
#endif
|