1 /* data.h -- 2 * Created: Sat Mar 15 18:04:25 2003 by Aleksey Cheusov <vle@gmx.net> 3 * Copyright 1994-2003 Rickard E. Faith (faith@dict.org) 4 * 5 * This program is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License as published by the 7 * Free Software Foundation; either version 1, or (at your option) any 8 * later version. 9 * 10 * This program is distributed in the hope that it will be useful, but 11 * WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 * General Public License for more details. 14 * 15 * You should have received a copy of the GNU General Public License along 16 * with this program; if not, write to the Free Software Foundation, Inc., 17 * 675 Mass Ave, Cambridge, MA 02139, USA. 18 */ 19 20 #ifndef _DATA_H_ 21 #define _DATA_H_ 22 23 #include "dictP.h" 24 #include "defs.h" 25 26 /* initialize .data file */ 27 extern dictData *dict_data_open ( 28 const char *filename, int computeCRC); 29 /* */ 30 extern void dict_data_close ( 31 dictData *data); 32 33 extern void dict_data_print_header( FILE *str, dictData *data ); 34 extern int dict_data_zip( 35 const char *inFilename, const char *outFilename, 36 const char *preFilter, const char *postFilter ); 37 38 extern char *dict_data_obtain ( 39 const dictDatabase *db, 40 const dictWord *dw); 41 42 extern char *dict_data_read_ ( 43 dictData *data, 44 unsigned long start, unsigned long end, 45 const char *preFilter, 46 const char *postFilter ); 47 48 extern int dict_data_filter( 49 char *buffer, int *len, int maxLength, 50 const char *filter ); 51 52 extern int mmap_mode; 53 54 #endif /* _DATA_H_ */ 55