|
Server 0.0.1
HTTP/REST server implementation
|
00001 00023 #include <search.h> 00024 00025 #include "hash.h" 00026 00027 static void (*cb)(void*); 00028 00029 static 00030 inline 00031 void 00032 walk(const void * node, const VISIT which, const int depth) 00033 { 00034 if (endorder == which || leaf == which) { 00035 cb(*(void**)node); 00036 } 00037 } 00038 00039 void 00040 hashEach(Hash this, void (*callback)(const void*)) 00041 { 00042 cb = callback; 00043 00044 twalk(this->root, walk); 00045 } 00046 00047 // vim: set ts=4 sw=4: