Merge branch 'master' of https://github.com/sunyinqi0508/AQuery
This commit is contained in:
@@ -139,4 +139,12 @@ void* Server::getCol(int col_idx){
|
||||
|
||||
Server::~Server(){
|
||||
close();
|
||||
}
|
||||
}
|
||||
|
||||
bool Server::havehge() {
|
||||
#if defined(_MONETDBE_LIB_) and defined(HAVE_HGE)
|
||||
return HAVE_HGE;
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
#ifndef __MONETDB_CONN_H__
|
||||
#define __MONETDB_CONN_H__
|
||||
|
||||
struct Context;
|
||||
|
||||
@@ -19,5 +21,8 @@ struct Server{
|
||||
void *getCol(int col_idx);
|
||||
void close();
|
||||
bool haserror();
|
||||
static bool havehge();
|
||||
~Server();
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
+4
-4
@@ -65,8 +65,8 @@ extern "C" int __DLLEXPORT__ binary_info() {
|
||||
}
|
||||
|
||||
__AQEXPORT__(bool) have_hge(){
|
||||
#if defined(_MONETDBE_LIB_) and defined(HAVE_HGE)
|
||||
return HAVE_HGE;
|
||||
#if defined(__MONETDB_CONN_H__)
|
||||
return Server::havehge();
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
@@ -105,10 +105,10 @@ int dll_main(int argc, char** argv, Context* cxt){
|
||||
}
|
||||
for(int i = 0; i < n_recv; ++i)
|
||||
{
|
||||
printf("%s, %d\n", n_recvd[i], n_recvd[i][0] == 'Q');
|
||||
//printf("%s, %d\n", n_recvd[i], n_recvd[i][0] == 'Q');
|
||||
if (n_recvd[i][0] == 'Q'){
|
||||
server->exec(n_recvd[i] + 1);
|
||||
printf("Exec Q%d: %s\n", i, n_recvd[i]);
|
||||
printf("Exec Q%d: %s", i, n_recvd[i]);
|
||||
}
|
||||
else if (n_recvd[i][0] == 'P' && handle && !server->haserror()) {
|
||||
code_snippet c = reinterpret_cast<code_snippet>(dlsym(handle, n_recvd[i]+1));
|
||||
|
||||
+1
-1
@@ -1,10 +1,10 @@
|
||||
#ifndef _TYPES_H
|
||||
#define _TYPES_H
|
||||
#include <typeinfo>
|
||||
#include <functional>
|
||||
#include <cstdint>
|
||||
#include <type_traits>
|
||||
#include <string>
|
||||
#include <tuple>
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#define __restrict__ __restrict
|
||||
|
||||
Reference in New Issue
Block a user