]> git.lyx.org Git - lyx.git/blob - src/support/lyxlib.h
make doc++ able to generate the source documentation for lyx
[lyx.git] / src / support / lyxlib.h
1 // -*- C++ -*-
2 /* This file is part of
3  * ====================================================== 
4  * 
5  *           LyX, The Document Processor
6  *        
7  *           Copyright 1995 Matthias Ettrich
8  *           Copyright 1995-2000 The LyX Team.
9  *
10  * ====================================================== */
11
12 #ifndef LYX_LIB_H
13 #define LYX_LIB_H
14
15 #include "LString.h"
16
17 // Where can I put this?  I found the occurence of the same code
18 // three/four times. Don't you think it better to use a macro definition
19 // (an inlined member of some class)?
20
21 // This should have been a namespace
22 #ifdef CXX_WORKING_NAMESPACES
23 ///
24 namespace lyx {
25         ///
26         char * getcwd(char * buffer, size_t size);
27         ///
28         int chdir(char const * name);
29         /// generates a checksum
30         unsigned long sum(char const * file);
31         /// returns a date string (not used currently)
32         char * date(); 
33         /// returns the name of the user (not used currently)
34         string getUserName();
35         ///
36         int kill(long int pid, int sig);
37         ///
38         void abort();
39         ///
40         int mkdir(char const * pathname, unsigned long int mode);
41         ///
42         int putenv(char const * str);
43 }
44 #else
45 ///
46 struct lyx {
47         ///
48         static char * getcwd(char * buffer, size_t size);
49         ///
50         static int chdir(char const * name);
51         /// generates a checksum
52         static unsigned long sum(char const * file);
53         /// returns a date string (not used currently)
54         static char * date(); 
55         /// returns the name of the user (not used currently)
56         static string getUserName();
57         ///
58         static int kill(long int pid, int sig);
59         ///
60         static void abort();
61         ///
62         static int mkdir(char const * pathname, unsigned long int mode);
63         ///
64         static int putenv(char const * str);
65 };
66 #endif // CXX_WORKING_NAMESPACES
67 #endif