header_complex.h
资源名称:snmp.src.rar [点击查看]
上传用户:cxs890
上传日期:2021-05-22
资源大小:347k
文件大小:2k
源码类别:
SNMP编程
开发平台:
C/C++
- /*
- * header_complex.h: More complex storage and data sorting for mib modules
- */
- #ifndef _MIBGROUP_HEADER_COMPLEX_H
- #define _MIBGROUP_HEADER_COMPLEX_H
- #ifdef __cplusplus
- extern "C" {
- #endif
- struct header_complex_index {
- oid *name;
- size_t namelen;
- void *data;
- struct header_complex_index *next;
- struct header_complex_index *prev;
- };
- /* Function pointer called by the header_comlpex functions when a client pointer (void * to us) needs to be cleaned. */
- typedef void (HeaderComplexCleaner)(void *);
- void *header_complex(struct header_complex_index *datalist, struct variable *vp,
- oid *name, size_t *length, int exact, size_t *var_len,
- WriteMethod **write_method);
- int header_complex_generate_varoid(struct variable_list *var);
- int header_complex_parse_oid(oid *oidIndex, size_t oidLen,
- struct variable_list *data);
- void header_complex_generate_oid(oid *name, size_t *length, oid *prefix,
- size_t prefix_len,
- struct variable_list *data);
- void header_complex_free_all(struct header_complex_index *thestuff,
- HeaderComplexCleaner *cleaner);
- void header_complex_free_entry(struct header_complex_index *theentry,
- HeaderComplexCleaner *cleaner);
- void *header_complex_extract_entry(struct header_complex_index **thetop,
- struct header_complex_index *thespot);
- struct header_complex_index *header_complex_find_entry(struct header_complex_index *thestuff, void *entry);
- struct header_complex_index *
- header_complex_add_data(struct header_complex_index **thedata,
- struct variable_list *var, void *data);
- #ifdef __cplusplus
- }
- #endif
- #endif /* _MIBGROUP_HEADER_COMPLEX_H */