J_CREATE(3)

FUNCTION
j_create - Create a general purpose associative array of key-value pairs.

SYNOPSIS
#include <karma_j.h>

KJoinedPairList j_create

(void *info, int (*key_compare_func) (CONST void *key1, CONST void *key2), void *(*key_copy_func) (CONST void *key, uaddr length, flag *ok), void (*key_destroy_func) (void *key))

DESCRIPTION
Create a general purpose associative array of key-value pairs.

info
    Arbitrary information to be stored with the associative array.

key_compare_func
    The function used to compare two keys. The prototype function is <-j_PROTO_key_compare_func->. If this is NULL, pointer values are compared.

key_copy_func
    The function used to copy keys. The prototype function is <-j_PROTO_key_copy_func->.

key_destroy_func
    The function used to destroy keys. The prototype function is <-j_PROTO_key_destroy_func->.

RETURN VALUE
An associative array on success, else NULL.

Multi-threading Level
Unsafe.

AUTHOR
Richard Gooch (rgooch@atnf.csiro.au)

AVAILABLITY
The Karma Distribution is available for anonymous ftp from: ftp://ftp.atnf.csiro.au/pub/software/karma/ ftp://wuarchive.wustl.edu/graphics/graphics/packages/karma/ ftp://ftp.pwr.wroc.pl/pub/karma/ The Karma Home Page is: http://www.atnf.csiro.au/karma/