DBFuns.h

00001 /***************************************************************************
00002  *   Copyright (C) 2007 by valter   *
00003  *   staroverovv@yandx.ru   *
00004  *                                                                         *
00005  *   This program is free software; you can redistribute it and/or modify  *
00006  *   it under the terms of the GNU General Public License as published by  *
00007  *   the Free Software Foundation; either version 2 of the License, or     *
00008  *   (at your option) any later version.                                   *
00009  *                                                                         *
00010  *   This program is distributed in the hope that it will be useful,       *
00011  *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
00012  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
00013  *   GNU General Public License for more details.                          *
00014  *                                                                         *
00015  *   You should have received a copy of the GNU General Public License     *
00016  *   along with this program; if not, write to the                         *
00017  *   Free Software Foundation, Inc.,                                       *
00018  *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
00019  ***************************************************************************/
00020 #ifndef __DBFUNS_H__
00021 #define __DBFUNS_H__
00022 #include <qstring.h>
00023 #include "str.h"
00024 #include "var.h"
00025 //===========================================================================
00026 class CMessageEvent; class CMessageEventRequest;
00027 //===========================================================================
00028 int DBGetSensors(int *N, CSensor **s, QDialog *dlg);
00029 int DBGetSensorsDebug(int *N, CSensor *s);
00030 extern int (*FInitDBSensors)(const char *ConfigWD);
00031 extern int (*FDBGetSensors)(int *N, CSensor **s);
00032 int InitDBSensors(QString ConfigWD);
00033 int InitDBSensorsDebug(QString ConfigWD);
00034 //===========================================================================
00035 extern int (*FInitDBEvents)(const char *ConfigWD);
00036 extern int (*FDBGetEvents)(int *N, CMessageEvent **event, CMessageEventRequest *request);
00037 extern int (*FDBDeleteEvent)(int ID);
00038 int DBGetEventsDebug(int *N, CMessageEvent *event, CMessageEventRequest *request);
00039 int DBGetEvents(int *N, CMessageEvent **event, CMessageEventRequest *request, QDialog *dlg);
00040 int InitDBEvents(QString ConfigDir);
00041 int InitDBEventsDebug(QString ConfigDir);
00042 int DBDeleteEvent(int ID);
00043 //===========================================================================
00044 extern int (*FInitDBCommands)(const char *ConfigWD);
00045 extern int (*FDBGetCommands)(int *N, CMessageCommand **Command, CMessageCommandRequest *request);
00046 extern int (*FDBPutCommand)(CMessageCommand *c);
00047 int DBGetCommandsDebug(int *N, CMessageCommand *event, CMessageCommandRequest *request);
00048 int DBGetCommands(int *N, CMessageCommand **Command, CMessageCommandRequest *request, QDialog *dlg);
00049 int InitDBCommands(QString ConfigDir);
00050 int InitDBCommandsDebug(QString ConfigDir);
00051 int DBPutCommand(CMessageCommand &c);
00052 int DBDeleteCommand(int ID);
00053 //===========================================================================
00054 typedef int (*TFDBGetSensors)(int *N, CSensor **s);
00055 typedef int (*TFInitDBSensors)(const char *ConfigWD);
00056 typedef int (*TFInitDBEvents)(const char *ConfigWD);
00057 typedef int (*TFDBGetEvents)(int *N, CMessageEvent **event, CMessageEventRequest *request);
00058 typedef int (*TFInitDBCommands)(const char *ConfigWD);
00059 typedef int (*TFDBGetCommands)(int *N, CMessageCommand **Command, CMessageCommandRequest *request);
00060 typedef int (*TFDBPutCommand)(CMessageCommand *Command);
00061 typedef int (*TFDBPutEvent)(CMessageEvent *event);
00062 typedef int (*TFDBDeleteCommand)(int ID);
00063 typedef int (*TFDBDeleteEvent)(int ID);
00064 //==========================================================================
00065 #endif
00066 
00067 

Generated on Thu Nov 15 16:34:53 2007 for wgr.kdevelop by  doxygen 1.4.7