#include <iostream>
#include <string>
#include <cassert>
#include "version.hpp"
#include <JRuncontrol/JDAQClient.hh>
#include <JLogger/JControlHostLogger.hh>
#include <JLogger/JMessageLogger.hh>
#include <JDAQ/JDAQTags.hh>
#include <boost/asio.hpp>
#include <boost/scoped_ptr.hpp>
#include <boost/program_options.hpp>
#include "configure.hpp"
Go to the source code of this file.
|  | 
|  | KM3NETDAQ | 
|  | KM3NeT DAQ data structures and auxiliaries. 
 | 
|  | 
|  | 
| int | main (int argc, char *argv[]) | 
|  | 
◆ main()
      
        
          | int main | ( | int | argc, | 
        
          |  |  | char * | argv[] | 
        
          |  | ) |  |  | 
      
 
Definition at line 140 of file monrouter.cpp.
  142   std::string server(
"localhost");
 
  143   std::string logger(
"localhost");
 
  144   std::string client_name(
"MonRouter");
 
  148   po::options_description desc(
"Options");
 
  150       (
"help,h", 
"Print this help and exit.")
 
  151       (
"version,v", 
"Print the version and exit.")
 
  154         , po::value<std::string>(&server)->default_value(server)
 
  155         , 
"Set the address of the SM server." 
  159         , po::value<std::string>(&logger)->default_value(logger)
 
  160         , 
"Set the address of the logger server." 
  164         , po::value<std::string>(&client_name)->default_value(client_name)
 
  165         , 
"Set the address of the client name." 
  169         , po::value<int>(&port)->required()
 
  170         , 
"Set the UDP port to read data from" 
  174         , po::value<int>(&
debug)->default_value(
debug)
 
  175         , 
"Set the debug level." 
  179     po::variables_map vm;
 
  181         po::command_line_parser(argc, argv).options(desc).run(),
 
  185     if (vm.count(
"help")) {
 
  186       std::cout << desc << std::endl;
 
  190     if (vm.count(
"version")) {
 
  196   } 
catch (
const po::error& e) {
 
  197     std::cerr << 
"MonRouter: Error: " << e.what() << 
'\n' 
  198               << desc << std::endl;
 
  200   } 
catch (
const std::runtime_error& e) {
 
  201     std::cerr << 
"MonRouter: Error: " << e.what() << 
'\n' 
  202               << desc << std::endl;
 
Message logging based on ControlHost.
void store(const std::string &file_name, const JDetector &detector)
Store detector to output file.