FairMQ  1.4.33
C++ Message Queuing Library and Framework
JSONParser.h
1 /********************************************************************************
2  * Copyright (C) 2014-2018 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH *
3  * *
4  * This software is distributed under the terms of the *
5  * GNU Lesser General Public Licence (LGPL) version 3, *
6  * copied verbatim in the file "LICENSE" *
7  ********************************************************************************/
8 /*
9  * File: FairMQParser.h
10  * Author: winckler
11  *
12  * Created on May 14, 2015, 5:01 PM
13  */
14 
15 #ifndef FAIR_MQ_JSONPARSER_H
16 #define FAIR_MQ_JSONPARSER_H
17 
18 #include <fairmq/Properties.h>
19 #include <boost/property_tree/ptree_fwd.hpp>
20 
21 #include <stdexcept>
22 #include <string>
23 
24 namespace fair::mq
25 {
26 
27 struct ParserError : std::runtime_error { using std::runtime_error::runtime_error; };
28 
29 fair::mq::Properties PtreeParser(const boost::property_tree::ptree& pt, const std::string& deviceId);
30 
31 fair::mq::Properties JSONParser(const std::string& filename, const std::string& deviceId);
32 
33 namespace helper
34 {
35 
36 fair::mq::Properties DeviceParser(const boost::property_tree::ptree& tree, const std::string& deviceId);
37 void ChannelParser(const boost::property_tree::ptree& tree, fair::mq::Properties& properties);
38 void SubChannelParser(const boost::property_tree::ptree& tree, fair::mq::Properties& properties, const std::string& channelName, const fair::mq::Properties& commonProperties);
39 
40 } // helper namespace
41 
42 } // namespace fair::mq
43 
44 #endif /* FAIR_MQ_JSONPARSER_H */
fair::mq
Tools for interfacing containers to the transport via polymorphic allocators.
Definition: DeviceRunner.h:23

privacy