summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--server/src/Makefile.am12
-rw-r--r--server/src/macro_parser.h2
-rw-r--r--server/src/queryhandler.cc (renamed from server/src/externaldataqueryhandler.cc)6
-rw-r--r--server/src/queryhandler.h (renamed from server/src/externaldataqueryhandler.h)16
-rw-r--r--server/src/queryparser.cc (renamed from server/src/externaldataqueryparser.cc)14
-rw-r--r--server/src/queryparser.h (renamed from server/src/externaldataqueryparser.h)14
-rw-r--r--server/src/saxparser.cc (renamed from server/src/sax_parser.cc)4
-rw-r--r--server/src/saxparser.h (renamed from server/src/sax_parser.h)8
-rw-r--r--server/src/templateparser.h2
-rw-r--r--server/src/xmlparser.h2
10 files changed, 40 insertions, 40 deletions
diff --git a/server/src/Makefile.am b/server/src/Makefile.am
index 4d64067..621e8dd 100644
--- a/server/src/Makefile.am
+++ b/server/src/Makefile.am
@@ -11,14 +11,14 @@ pracrod_SOURCES = \
database.cc \
configuration.cc \
exception.cc \
- externaldataqueryhandler.cc \
- externaldataqueryparser.cc \
+ queryhandler.cc \
+ queryparser.cc \
journal_commit.cc \
log.cc \
luaquerymapper.cc \
macro_parser.cc \
resumeparser.cc \
- sax_parser.cc \
+ saxparser.cc \
server.cc \
templateparser.cc \
tcpsocket.cc \
@@ -32,15 +32,15 @@ EXTRA_DIST = \
database.h \
debug.h \
exception.h \
- externaldataqueryhandler.h \
- externaldataqueryparser.h \
+ queryhandler.h \
+ queryparser.h \
journal_commit.h \
log.h \
luaquerymapper.h \
macro.h \
macro_parser.h \
resumeparser.h \
- sax_parser.h \
+ saxparser.h \
server.h \
templateparser.h \
tcpsocket.h \
diff --git a/server/src/macro_parser.h b/server/src/macro_parser.h
index 248e586..7200551 100644
--- a/server/src/macro_parser.h
+++ b/server/src/macro_parser.h
@@ -29,7 +29,7 @@
#include <string>
-#include "sax_parser.h"
+#include "saxparser.h"
#include "macro.h"
class MacroParser : public SAXParser {
diff --git a/server/src/externaldataqueryhandler.cc b/server/src/queryhandler.cc
index c6aed15..16db038 100644
--- a/server/src/externaldataqueryhandler.cc
+++ b/server/src/queryhandler.cc
@@ -1,6 +1,6 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/***************************************************************************
- * externaldataqueryhandler.cc
+ * queryhandler.cc
*
* Tue May 6 14:50:56 CEST 2008
* Copyright 2008 Bent Bisballe Nyeng, Lars Bisballe Jensen and Peter Skaarup
@@ -24,8 +24,8 @@
* along with Pracro; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
*/
-#include "externaldataqueryhandler.h"
+#include "queryhandler.h"
-ExternalDataQueryHandler::ExternalDataQueryHandler()
+QueryHandler::QueryHandler()
{
}
diff --git a/server/src/externaldataqueryhandler.h b/server/src/queryhandler.h
index 375ffa2..2de62ae 100644
--- a/server/src/externaldataqueryhandler.h
+++ b/server/src/queryhandler.h
@@ -1,6 +1,6 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/***************************************************************************
- * externaldataqueryhandler.h
+ * queryhandler.h
*
* Tue May 6 14:50:55 CEST 2008
* Copyright 2008 Bent Bisballe Nyeng, Lars Bisballe Jensen and Peter Skaarup
@@ -24,23 +24,23 @@
* along with Pracro; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
*/
-#ifndef __PRACRO_EXTERNALDATAQUERYHANDLER_H__
-#define __PRACRO_EXTERNALDATAQUERYHANDLER_H__
+#ifndef __PRACRO_QUERYHANDLER_H__
+#define __PRACRO_QUERYHANDLER_H__
-class ExternalDataQuery {};
+class Query {};
/**
* This class handles the query of external data.
*/
-class ExternalDataQueryHandler {
+class QueryHandler {
public:
- ExternalDataQueryHandler();
+ QueryHandler();
// Add a query to the query queue
- void addQuery(ExternalDataQuery &query) {}
+ void addQuery(Query &query) {}
// Execute all queries in parallel, for speed improv.
void exec() {}
};
-#endif/*__PRACRO_EXTERNALDATAQUERYHANDLER_H__*/
+#endif/*__PRACRO_QUERYHANDLER_H__*/
diff --git a/server/src/externaldataqueryparser.cc b/server/src/queryparser.cc
index 2de7fba..38e3037 100644
--- a/server/src/externaldataqueryparser.cc
+++ b/server/src/queryparser.cc
@@ -1,6 +1,6 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/***************************************************************************
- * externaldataqueryparser.cc
+ * queryparser.cc
*
* Tue May 6 17:02:37 CEST 2008
* Copyright 2008 Bent Bisballe Nyeng, Lars Bisballe Jensen and Peter Skaarup
@@ -24,16 +24,16 @@
* along with Pracro; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
*/
-#include "externaldataqueryparser.h"
+#include "queryparser.h"
-ExternalDataQueryParser::ExternalDataQueryParser(std::string document)
+QueryParser::QueryParser(std::string document)
{
this->document = document;
p = 0;
stack.push_back(&result);
}
-void ExternalDataQueryParser::startTag(std::string name, std::map< std::string, std::string> attributes)
+void QueryParser::startTag(std::string name, std::map< std::string, std::string> attributes)
{
if(name == "group") {
@@ -48,13 +48,13 @@ void ExternalDataQueryParser::startTag(std::string name, std::map< std::string,
}
-void ExternalDataQueryParser::endTag(std::string name)
+void QueryParser::endTag(std::string name)
{
if(name == "group") stack.pop_back();
}
// FIXME: This is *not* the optimal way to do this.
-int ExternalDataQueryParser::readData(char *data, size_t size)
+int QueryParser::readData(char *data, size_t size)
{
size_t len = document.size() - p < size ? document.size() - p : size;
strncpy(data, document.c_str() + p, len);
@@ -101,7 +101,7 @@ char xml[] =
int main()
{
- ExternalDataQueryParser e(xml);
+ QueryParser e(xml);
e.parse();
printf("%s\n", loadresultstring(e.result).c_str());
diff --git a/server/src/externaldataqueryparser.h b/server/src/queryparser.h
index 1b760de..58f7f37 100644
--- a/server/src/externaldataqueryparser.h
+++ b/server/src/queryparser.h
@@ -1,6 +1,6 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/***************************************************************************
- * externaldataqueryparser.h
+ * queryparser.h
*
* Tue May 6 17:02:36 CEST 2008
* Copyright 2008 Bent Bisballe Nyeng, Lars Bisballe Jensen and Peter Skaarup
@@ -24,20 +24,20 @@
* along with Pracro; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
*/
-#ifndef __PRACRO_EXTERNALDATAQUERYPARSER_H__
-#define __PRACRO_EXTERNALDATAQUERYPARSER_H__
+#ifndef __PRACRO_QUERYPARSER_H__
+#define __PRACRO_QUERYPARSER_H__
#include "queryresult.h"
-#include "sax_parser.h"
+#include "saxparser.h"
#include <vector>
/**
* This class parses xml entyties into a QueryResult structure.
*/
-class ExternalDataQueryParser : public SAXParser {
+class QueryParser : public SAXParser {
public:
- ExternalDataQueryParser(std::string document);
+ QueryParser(std::string document);
void startTag(std::string name, std::map< std::string, std::string> attributes);
void endTag(std::string name);
@@ -55,4 +55,4 @@ private:
std::vector< QueryResult * > stack;
};
-#endif/*__PRACRO_EXTERNALDATAQUERYPARSER_H__*/
+#endif/*__PRACRO_QUERYPARSER_H__*/
diff --git a/server/src/sax_parser.cc b/server/src/saxparser.cc
index dd0a7a3..e0d849a 100644
--- a/server/src/sax_parser.cc
+++ b/server/src/saxparser.cc
@@ -1,6 +1,6 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/***************************************************************************
- * sax_parser.cc
+ * saxparser.cc
*
* Mon Mar 24 14:40:15 CET 2008
* Copyright 2008 Bent Bisballe Nyeng, Lars Bisballe Jensen and Peter Skaarup
@@ -24,7 +24,7 @@
* along with Pracro; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
*/
-#include "sax_parser.h"
+#include "saxparser.h"
static void start_hndl(void *p, const char *el, const char **attr)
{
diff --git a/server/src/sax_parser.h b/server/src/saxparser.h
index b6b48ba..c03b281 100644
--- a/server/src/sax_parser.h
+++ b/server/src/saxparser.h
@@ -1,6 +1,6 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/***************************************************************************
- * sax_parser.h
+ * saxparser.h
*
* Mon Mar 24 14:40:15 CET 2008
* Copyright 2008 Bent Bisballe Nyeng, Lars Bisballe Jensen and Peter Skaarup
@@ -24,8 +24,8 @@
* along with Pracro; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
*/
-#ifndef __PRACRO_SAX_PARSER_H__
-#define __PRACRO_SAX_PARSER_H__
+#ifndef __PRACRO_SAXPARSER_H__
+#define __PRACRO_SAXPARSER_H__
#include <string>
#include <map>
@@ -47,4 +47,4 @@ private:
XML_Parser p;
};
-#endif/*__PRACRO_SAX_PARSER_H__*/
+#endif/*__PRACRO_SAXPARSER_H__*/
diff --git a/server/src/templateparser.h b/server/src/templateparser.h
index c53b04d..d5c09b1 100644
--- a/server/src/templateparser.h
+++ b/server/src/templateparser.h
@@ -27,7 +27,7 @@
#ifndef __PRACRO_TEMPLATEPARSER_H__
#define __PRACRO_TEMPLATEPARSER_H__
-#include "sax_parser.h"
+#include "saxparser.h"
#include "template.h"
typedef enum {
diff --git a/server/src/xmlparser.h b/server/src/xmlparser.h
index 30e6767..1a37e26 100644
--- a/server/src/xmlparser.h
+++ b/server/src/xmlparser.h
@@ -27,7 +27,7 @@
#ifndef __PRACRO_XMLPARSER_H__
#define __PRACRO_XMLPARSER_H__
-#include "sax_parser.h"
+#include "saxparser.h"
#include "tcpsocket.h"
#include "transaction.h"