wfut  0.2.4
A client side C++ implementation of WFUT (WorldForge Update Tool).
FileIO.h
1 // This file may be redistributed and modified only under the terms of
2 // the GNU Lesser General Public License (See COPYING for details).
3 // Copyright (C) 2005 - 2007 Simon Goodall
4 
5 #ifndef LIBWFUT_FILEIO_H
6 #define LIBWFUT_FILEIO_H 1
7 
8 #include <string>
9 
10 #include <libwfut/types.h>
11 
12 namespace WFUT {
13 
14 class ChannelFileList;
15 
16 static const std::string TAG_filename = "filename";
17 static const std::string TAG_version = "version";
18 static const std::string TAG_crc32 = "crc32";
19 static const std::string TAG_size = "size";
20 static const std::string TAG_execute = "execute";
21 static const std::string TAG_file = "file";
22 static const std::string TAG_filelist = "fileList";
23 static const std::string TAG_dir = "dir";
24 static const std::string TAG_deleted = "deleted";
25 
26 int parseFileList(const std::string &filename, ChannelFileList &files);
27 int parseFileListXML(const std::string &xml, ChannelFileList &files);
28 
29 int writeFileList(const std::string &filename, const ChannelFileList &files);
30 } /* namespace WFUT */
31 
32 #endif /* LIBWFUT_FILEIO_H */