modified to support REST receiver, still not properly working

This commit is contained in:
sala 2014-09-15 16:52:53 +02:00
parent 7986746194
commit cfacc6ad6e
2 changed files with 13 additions and 4 deletions

View File

@ -15,9 +15,16 @@ CFLAGS= -g -DC_ONLY -fPIC
DFLAGS= -g -DDACS_INT -DSLS_RECEIVER_UDP_FUNCTIONS
INCLUDES?= -Iinclude -I../slsDetectorCalibration -I$(ASM)
INCLUDES?= $(INCLUDESRXR) -I include/ -I ../slsDetectorCalibration
#-Iinclude -I../slsDetectorCalibration -I$(ASM)
SRC_CLNT = MySocketTCP.cpp UDPInterface.cpp UDPBaseImplementation.cpp UDPStandardImplementation.cpp slsReceiverTCPIPInterface.cpp slsReceiver.cpp slsReceiverUsers.cpp utilities.cpp
ifeq ($(REST), yes)
SRC_CLNT += UDPRESTImplementation.cpp
endif
MAIN_SRC = main.cpp
OBJS=$(SRC_CLNT:%.cpp=$(BUILDDIR)/%.o)

View File

@ -23,6 +23,7 @@ using namespace std;
#include "UDPInterface.h"
#include "UDPBaseImplementation.h"
#include "UDPStandardImplementation.h"
#include "UDPRESTImplementation.h"
@ -35,10 +36,11 @@ UDPInterface * UDPInterface::create(string receiver_type){
return new UDPStandardImplementation();
}
#ifdef REST
else if (receiver_type == "REST")
//#ifdef REST
else if (receiver_type == "REST"){
return new UDPRESTImplementation();
#endif
}
//#endif
else{
FILE_LOG(logWARNING) << "[ERROR] UDP interface not supported, using standard implementation";
return new UDPBaseImplementation();