Copyright (C) 2000-2012 |
GNU Info (slib.info)Hash TablesHash Tables ----------- `(require 'hash-table)' - Function: predicate->hash pred Returns a hash function (like `hashq', `hashv', or `hash') corresponding to the equality predicate PRED. PRED should be `eq?', `eqv?', `equal?', `=', `char=?', `char-ci=?', `string=?', or `string-ci=?'. A hash table is a vector of association lists. - Function: make-hash-table k Returns a vector of K empty (association) lists. Hash table functions provide utilities for an associative database. These functions take an equality predicate, PRED, as an argument. PRED should be `eq?', `eqv?', `equal?', `=', `char=?', `char-ci=?', `string=?', or `string-ci=?'. - Function: predicate->hash-asso pred Returns a hash association function of 2 arguments, KEY and HASHTAB, corresponding to PRED. The returned function returns a key-value pair whose key is PRED-equal to its first argument or `#f' if no key in HASHTAB is PRED-equal to the first argument. - Function: hash-inquirer pred Returns a procedure of 2 arguments, HASHTAB and KEY, which returns the value associated with KEY in HASHTAB or `#f' if KEY does not appear in HASHTAB. - Function: hash-associator pred Returns a procedure of 3 arguments, HASHTAB, KEY, and VALUE, which modifies HASHTAB so that KEY and VALUE associated. Any previous value associated with KEY will be lost. - Function: hash-remover pred Returns a procedure of 2 arguments, HASHTAB and KEY, which modifies HASHTAB so that the association whose key is KEY is removed. - Function: hash-map proc hash-table Returns a new hash table formed by mapping PROC over the keys and values of HASH-TABLE. PROC must be a function of 2 arguments which returns the new value part. - Function: hash-for-each proc hash-table Applies PROC to each pair of keys and values of HASH-TABLE. PROC must be a function of 2 arguments. The returned value is unspecified. automatically generated by info2www version 1.2.2.9 |