New commit utilities - used for 'save' update.
[idzebra-moved-to-github.git] / include / bfile.h
1 /*
2  * Copyright (C) 1994-1995, Index Data I/S 
3  * All rights reserved.
4  * Sebastian Hammer, Adam Dickmeiss
5  *
6  * $Log: bfile.h,v $
7  * Revision 1.11  1995-12-08 16:20:39  adam
8  * New commit utilities - used for 'save' update.
9  *
10  * Revision 1.10  1995/12/01  16:24:33  adam
11  * Commit files use separate meta file area.
12  *
13  * Revision 1.9  1995/12/01  11:37:46  adam
14  * Cached/commit files implemented as meta-files.
15  *
16  * Revision 1.8  1995/11/30  08:33:29  adam
17  * Started work on commit facility.
18  *
19  * Revision 1.7  1995/09/04  12:33:35  adam
20  * Various cleanup. YAZ util used instead.
21  *
22  * Revision 1.6  1994/09/14  13:10:35  quinn
23  * Small changes
24  *
25  * Revision 1.5  1994/08/24  08:45:52  quinn
26  * Using mfile.
27  *
28  * Revision 1.4  1994/08/17  15:38:28  adam
29  * Include of util.h.
30  *
31  * Revision 1.3  1994/08/17  14:09:47  quinn
32  * Small changes
33  *
34  */
35
36 #ifndef BFILE_H
37 #define BFILE_H
38
39 #include <alexutil.h>
40 #include <mfile.h>
41
42 #define bf_blocksize(bf) mf_blocksize(bf->mf)
43
44 typedef struct BFile_struct
45 {
46     MFile mf;
47     struct CFile_struct *cf;
48 } *BFile, BFile_struct;
49
50 int bf_close (BFile);
51 BFile bf_open (const char *name, int block_size, int wflag);
52 int bf_read (BFile bf, int no, int offset, int num, void *buf);
53 int bf_write (BFile bf, int no, int offset, int num, const void *buf);
54 void bf_cache (int enableFlag);
55 int bf_commitExists (void);
56 void bf_commitExec (void);
57 void bf_commitClean (void);
58
59 #endif