version 1.1.2.1, 2022/01/04 22:32:34
|
version 1.3, 2025/08/21 15:43:00
|
Line 12 terms:
|
Line 12 terms:
|
All of the documentation and software included in the ELWIX and AITNET |
All of the documentation and software included in the ELWIX and AITNET |
Releases is copyrighted by ELWIX - Sofia/Bulgaria <info@elwix.org> |
Releases is copyrighted by ELWIX - Sofia/Bulgaria <info@elwix.org> |
|
|
Copyright 2004 - 2022 | Copyright 2004 - 2024 |
by Michael Pounov <misho@elwix.org>. All rights reserved. |
by Michael Pounov <misho@elwix.org>. All rights reserved. |
|
|
Redistribution and use in source and binary forms, with or without |
Redistribution and use in source and binary forms, with or without |
Line 61 struct tagIndex {
|
Line 61 struct tagIndex {
|
typedef struct tagIndex index_t; |
typedef struct tagIndex index_t; |
|
|
/* |
/* |
* index_get() - Get hash like list or first pointer | * index_getList() - Get hash like list or first pointer |
*/ |
*/ |
#define index_get(x, k) (x)->i_hash[(k)] | #define index_getList(x, k) (x)->i_hash[(k)] |
| #define index_Next(x) (x)->il_next |
#define index_Hash(x) (x)->il_hash |
#define index_Hash(x) (x)->il_hash |
#define index_Len(x) (x)->il_len |
#define index_Len(x) (x)->il_len |
#define index_Ptr(x) (x)->il_ptr |
#define index_Ptr(x) (x)->il_ptr |
|
|
|
#ifdef __cplusplus |
|
extern "C" { |
|
#endif |
|
|
/* |
/* |
* index_Init() - Init index structure |
* index_Init() - Init index structure |
Line 80 index_t *index_Init(index_t * __restrict idx);
|
Line 84 index_t *index_Init(index_t * __restrict idx);
|
* index_FreeLists() - Free linked lists with data |
* index_FreeLists() - Free linked lists with data |
* |
* |
* @idx = index |
* @idx = index |
* return: no result | * return: none |
*/ |
*/ |
void index_FreeLists(index_t *idx); |
void index_FreeLists(index_t *idx); |
/* |
/* |
* index_Destroy() - Destroy index |
* index_Destroy() - Destroy index |
* |
* |
* @idx = index |
* @idx = index |
* return: no result | * return: none |
*/ |
*/ |
void index_Destroy(index_t **idx); |
void index_Destroy(index_t **idx); |
|
|
Line 114 int index_add(index_t *idx, unsigned short key, void *
|
Line 118 int index_add(index_t *idx, unsigned short key, void *
|
*/ |
*/ |
int index_del(index_t *idx, unsigned short key, void *data, int datlen); |
int index_del(index_t *idx, unsigned short key, void *data, int datlen); |
/* |
/* |
|
* index_del2() - Dels item with index key and hash |
|
* |
|
* @idx = index |
|
* @key = hash key |
|
* @hash = calculated hash of item when its added to index |
|
* return: -1 error, 0 nothing deleted and 1 item deleted |
|
*/ |
|
int index_del2(index_t *idx, unsigned short key, unsigned int hash); |
|
/* |
* index_delList() - Delete list behind key |
* index_delList() - Delete list behind key |
* |
* |
* @idx = index |
* @idx = index |
Line 149 index_list_t index_get2(index_t *idx, unsigned short k
|
Line 162 index_list_t index_get2(index_t *idx, unsigned short k
|
*/ |
*/ |
ait_val_t *index_getVar(index_t *idx, u_short key, u_int hash); |
ait_val_t *index_getVar(index_t *idx, u_short key, u_int hash); |
|
|
|
|
|
/* |
|
* index_dump() - Debug routine about index hashes |
|
* |
|
* @idx = index |
|
* return: none |
|
*/ |
|
void index_dump(index_t *idx); |
|
|
|
#ifdef __cplusplus |
|
} |
|
#endif |
|
|
#endif |
#endif |