otsdaq  v2_05_02_indev
UDPDataStreamerBase.cc
1 #include "otsdaq/NetworkUtilities/UDPDataStreamerBase.h"
2 #include "otsdaq/Macros/CoutMacros.h"
3 
4 #include <iostream>
5 
6 using namespace ots;
7 
8 // NOTE: if you want to inherit from this one you MUST initialize
9 // the Socket Constructor that is commented out here in your class
10 //==============================================================================
11 UDPDataStreamerBase::UDPDataStreamerBase(std::string IPAddress, unsigned int port, std::string toIPAddress, unsigned int toPort)
12  : TransmitterSocket(IPAddress, port), streamToSocket_(toIPAddress, toPort)
13 {
14  __COUT__ << "IPAddress " << IPAddress << std::endl;
15  __COUT__ << "port " << port << std::endl;
16  __COUT__ << "toIPAddress " << toIPAddress << std::endl;
17  __COUT__ << "toPort " << toPort << std::endl;
18  __COUT__ << std::endl;
19  __COUT__ << std::endl;
20  __COUT__ << std::endl;
21  __COUT__ << std::endl;
22  __COUT__ << std::endl;
23 
24  Socket::initialize();
25  __COUT__ << "done!" << std::endl;
26 }
27 
28 //==============================================================================
29 UDPDataStreamerBase::~UDPDataStreamerBase(void) {}