implemented log file monitoring using Windows VSS snapshots
[public/netxms.git] / src / libnxlp / libnxlp.h
1 /*
2 ** NetXMS - Network Management System
3 ** Log Parsing Library
4 ** Copyright (C) 2003-2010 Victor Kirhenshtein
5 **
6 ** This program is free software; you can redistribute it and/or modify
7 ** it under the terms of the GNU Lesser General Public License as published by
8 ** the Free Software Foundation; either version 3 of the License, or
9 ** (at your option) any later version.
10 **
11 ** This program is distributed in the hope that it will be useful,
12 ** but WITHOUT ANY WARRANTY; without even the implied warranty of
13 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 ** GNU General Public License for more details.
15 **
16 ** You should have received a copy of the GNU Lesser General Public License
17 ** along with this program; if not, write to the Free Software
18 ** Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
19 **
20 ** File: libnxlp.h
21 **
22 **/
23
24 #ifndef _libnxlp_h_
25 #define _libnxlp_h_
26
27 #include <nms_common.h>
28 #include <nms_util.h>
29 #include <nxlpapi.h>
30
31 void LogParserTrace(int level, const TCHAR *format, ...);
32
33 #ifdef _WIN32
34
35 class IVssBackupComponents;
36
37 class FileSnapshot
38 {
39 private:
40 IVssBackupComponents *m_handle;
41 TCHAR *m_name;
42
43 FileSnapshot();
44
45 public:
46 static FileSnapshot *create(const TCHAR *path);
47
48 ~FileSnapshot();
49
50 const TCHAR *name() const { return m_name; }
51 };
52
53 THREAD_RESULT THREAD_CALL ParserThreadEventLog(void *);
54 bool InitEventLogParsersV6();
55 void InitEventLogParsers();
56 void CleanupEventLogParsers();
57
58 #endif
59
60 #endif