librnr/hash.c
bool_t hash_insert(hash_t *hash, void *key, void *data)
{
  hnode_t *node = hnode_create(data);

  if (node)
  {
    hash_node_insert(hash, node, key);
    return true;
  }

  return false;
}
/*!
 * \brief Insert user data with the given key into the hash table.
 *
 * The data and key are attached to new hash node which is automatically
 * allocated and the node is inserted into the hash table.
 *
 * \param hash  Hash table.
 * \param key   Hash key.
 * \param data  User data.
 *
 * \return Returns true if successful, else returns false.
 *
 * \exception "Not Initialzed"  Hashing not initialized.
 * \exception "Too Big" Reached maximum table size.
 * \exception "Duplicate Key" Node with key already exists.
 * \exception "Verification Failed" Only if \ref hash_self_verify enabled.
 */
\brief Insert user data with the given key into the hash table.
The data and key are attached to new hash node which is automatically
allocated and the node is inserted into the hash table.

\param hash  Hash table.
\param key   Hash key.
\param data  User data.

\return Returns true if successful, else returns false.

\exception "Not Initialzed"  Hashing not initialized.
\exception "Too Big" Reached maximum table size.
\exception "Duplicate Key" Node with key already exists.
\exception "Verification Failed" Only if \ref hash_self_verify enabled.
\ brief Insert user data with the given key into the hash table . The data and key are attached to new hash node which is automatically allocated and the node is inserted into the hash table . \ param hash Hash table . \ param key Hash key . \ param data User data . \ return Returns true if successful else returns false . \ exception " Not Initialzed " Hashing not initialized . \ exception " Too Big " Reached maximum table size . \ exception " Duplicate Key " Node with key already exists . \ exception " Verification Failed " Only if \ ref hash_self_verify enabled .
bool_t hash_insert(hash_t *hash, void *key, void *data)
{
  hnode_t *node = hnode_create(data);
  if (node)
  {
    hash_node_insert(hash, node, key);
    return true;
  }
  return false;
}
bool_t hash_insert ( hash_t * hash , void * key , void * data ) { hnode_t * node = hnode_create ( data ) ; if ( node ) { hash_node_insert ( hash , node , key ) ; return true ; } return false ; }
\brief Insert user data with the given key into the hash table.
\ brief Insert user data with the given key into the hash table .