diff options
Diffstat (limited to 'docs/cmap_api.md')
| -rw-r--r-- | docs/cmap_api.md | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/docs/cmap_api.md b/docs/cmap_api.md index 5c029a29..c5311e27 100644 --- a/docs/cmap_api.md +++ b/docs/cmap_api.md @@ -17,19 +17,23 @@ See the c++ class [std::unordered_map](https://en.cppreference.com/w/cpp/contain ## Header file and declaration ```c -#define i_key // key: REQUIRED -#define i_val // value: REQUIRED -#define i_cmp // three-way compare two i_keyraw*: REQUIRED IF i_keyraw is non-integral type -#define i_eq // equality comparison two i_keyraw*: ALTERNATIVE to i_cmp +#define i_key // hash key: REQUIRED +#define i_val // map value: REQUIRED +#define i_hash // hash func i_keyraw*: REQUIRED IF i_keyraw is non-pod type +#define i_eq // equality comparison two i_keyraw*: REQUIRED IF i_keyraw is a + // non-integral type. Three-way i_cmp may be specified alternatively. #define i_keydrop // destroy key func - defaults to empty destruct #define i_keyraw // convertion "raw" type - defaults to i_key #define i_keyfrom // convertion func i_keyraw => i_key - defaults to plain copy #define i_keyto // convertion func i_key* => i_keyraw - defaults to plain copy + #define i_valdrop // destroy value func - defaults to empty destruct #define i_valraw // convertion "raw" type - defaults to i_val #define i_valfrom // convertion func i_valraw => i_val - defaults to plain copy #define i_valto // convertion func i_val* => i_valraw - defaults to plain copy -#define i_tag // defaults to i_key + +#define i_tag // typename tag. defaults to i_key +#define i_type // full typename of the container #include <stc/cmap.h> ``` `X` should be replaced by the value of `i_tag` in all of the following documentation. |
