1 #ifndef ADF_BITM_H
2 #define ADF_BITM_H
3 /*
4  *  ADF Library. (C) 1997-2002 Laurent Clevy
5  *
6  *  adf_bitm.h
7  *
8  *  $Id$
9  *
10  *  bitmap code
11  *
12  *  This file is part of ADFLib.
13  *
14  *  ADFLib is free software; you can redistribute it and/or modify
15  *  it under the terms of the GNU General Public License as published by
16  *  the Free Software Foundation; either version 2 of the License, or
17  *  (at your option) any later version.
18  *
19  *  ADFLib is distributed in the hope that it will be useful,
20  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
21  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
22  *  GNU General Public License for more details.
23  *
24  *  You should have received a copy of the GNU General Public License
25  *  along with Foobar; if not, write to the Free Software
26  *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
27  *
28  */
29 
30 #include"adf_str.h"
31 #include"prefix.h"
32 
33 RETCODE adfReadBitmapBlock(struct Volume*, SECTNUM nSect, struct bBitmapBlock*);
34 RETCODE adfWriteBitmapBlock(struct Volume*, SECTNUM nSect, struct bBitmapBlock*);
35 RETCODE adfReadBitmapExtBlock(struct Volume*, SECTNUM nSect, struct bBitmapExtBlock*);
36 RETCODE adfWriteBitmapExtBlock(struct Volume*, SECTNUM, struct bBitmapExtBlock* );
37 
38 SECTNUM adfGet1FreeBlock(struct Volume *vol);
39 RETCODE adfUpdateBitmap(struct Volume *vol);
40 PREFIX int32_t adfCountFreeBlocks(struct Volume* vol);
41 RETCODE adfReadBitmap(struct Volume* , SECTNUM nBlock, struct bRootBlock* root);
42 BOOL adfIsBlockFree(struct Volume* vol, SECTNUM nSect);
43 void adfSetBlockFree(struct Volume* vol, SECTNUM nSect);
44 void adfSetBlockUsed(struct Volume* vol, SECTNUM nSect);
45 BOOL adfGetFreeBlocks(struct Volume* vol, int nbSect, SECTNUM* sectList);
46 RETCODE adfCreateBitmap(struct Volume *vol);
47 RETCODE adfWriteNewBitmap(struct Volume *vol);
48 void adfFreeBitmap(struct Volume *vol);
49 
50 #endif /* ADF_BITM_H */
51 
52 /*#######################################################################################*/
53