This is implementation of Bayer-Trees, which are normally used for indices of data bases. These routines provide all stuff that is needed to create and destroy; insert, update and delete; load and destroy; search and traverse; check a tree. Sort huge amounts of data by doing a multi-phase sorting on temporary files.
This implementation automatically recognizes if the input data fits completely into memory and then does a in-place sort via quicksort. If you don’t have an ANSI-C compiler, get one (for example GNU-C)
or forget about this program (it uses prototyping with ANSI-C style
prototypes, so a K&R compiler won’t work). I do *not* support ancient
To configure the program, edit the file “jsconfig.h”. Since this is a general configuration file, not all settings may apply to this package. If in doubt, use grep or anything else to find out if a specific configuration symbol is used somewhere.
No default optimization option is used in the Makefile since this is compiler dependent. One has to find out what option produces the best result on the platform. Check the manual of your C-compiler for more information. The variable COPTIMIZE is reserved for optimization. For some systems I have experience with optimization options are given at the beginning of the Makefile, uncomment them for your system.
– The file “ErrCodes.c” contains an array of all error messages that will be produced by the library routines, similar to the ANSI “strerror”-function.Â The library can be configured to load error messages only on demand from the file “Error.txt” which contains the error messages as ASCII text.
This saves space in the executables. For that the file “Error.txt” has to be installed globally accessible in a fixed place and the path name of the file has to be defined like
#define CONFIG_ERRMSGFILE “/this/is/the/path/name”
while compiling the package (see “jsconfig.h”).
This program is Copyright ? 1993-1995 by Joerg Schoen. Permission to use, copy and distribute this software together with its documentation for any purpose is herby granted provided that the above copyright notice appears in all copies. No fee must be taken for this package. This software is provided “as is” without expressed or implied warranty.
Bug reports, questions, improvements, mail to JÃ¶rg SchÃ¶n
B-Tree implementation (48.0 KiB, 15,985 hits)