dbh_fanout man page on DragonFly

Man page or keyword search:  
man Server   44335 pages
apropos Keyword Search (all sections)
Output format
DragonFly logo
[printable version]

dbh_sweep(3)	       DBHashTables Programmers' Manual		  dbh_sweep(3)NAME
       dbh_sweep,     dbh_fanout,    dbh_foreach_sweep,	   dbh_foreach_fanout,
       dbh_exit_sweep, dbh_exit_fanout - apply a function to all  or  part  of
       the DBHashtable

SYNOPSIS
       #include <dbh.h>

       int dbh_foreach_sweep (DBHashTable *dbh, DBHashFunc operate);
       int dbh_foreach_fanout (DBHashTable *dbh, DBHashFunc operate);
       int  dbh_sweep  (DBHashTable  *dbh,  DBHashFunc	operate, unsigned char
       *key1, unsigned char *key2, unsigned char ignore_portion);
       int dbh_fanout (DBHashTable *dbh,  DBHashFunc  operate,	unsigned  char
       *key1, unsigned char *key2, unsigned char ignore_portion);
       void dbh_exit_sweep (DBHashTable *dbh);
       void dbh_exit_fanout (DBHashTable *dbh);

DESCRIPTION
       dbh_foreach_sweep  applies function operate to each member of the hash,
       following  a  sweep  trajectory.	  Sweep	 is  done  by  traversing  the
       DBHashTable in a vertical direction through all branches.

       dbh_foreach_fanout  applies  a  function	 operate to each member of the
       hash, following a fanout trajectory. Fanout is done by  traversing  the
       DBHashTable in a horizontal direction through all records.

       dbh_sweep  and  dbh_fanout  apply  a function to subtree members of the
       hash, where dbh_sweep follows a sweep  trajectory  (vertically  through
       branches)  and  dbh_fanout  follows  a  fanout trajectory (horizontally
       through branches).

       key1 is the key from which to start the sweep or NULL if you don't care
       and  want  to start at the top.	If you decide to define key1 make sure
       it is a top level node of a subtree. This is done with dbh_find
       key2 is the key which will trigger an exit condition, or NULL if	 don't
       care and want to continue until the end of the DBHashTable
       ignore_portion  allows you to define the ignored trailing bytes of key1
       which will define the size of the subtree to be sweeped, or zero if you
       don't care and want to process all branches.

       In  these  functions, operate ( void (*operate) (DBHashTable *dbh) ) is
       the function to apply to each selected member of the DBHashTable

       dbh_exit_sweep and dbh_exit_fanout within  the  operate	function  will
       cause the exit of a currently running sweep or fanout.

RETURN VALUE
       0 on error, 1 otherwise.

NOTES
       In  order  for  sweep/fanout functions to be extremely fast, you should
       prepare the DBHashTable for the	trajectory  you	 intend	 to  use  with
       dbh_regen_sweep	or  dbh_regen_fanout  first. This allows for extremely
       efficient use of hardware and operating system caches.

SEE ALSO
       dbh (0),	 dbh_regen_sweep  (3),	dbh_regen_fanout  (3),	dbh_find  (3),
       dbh_settempdir (3)

Author
       Edscott Wilson Garcia <edscott@xfce.org>

DBHashTables			      DBH			  dbh_sweep(3)
[top]

List of man pages available for DragonFly

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net