Diag-Client-Lib
config_parser_type.h
Go to the documentation of this file.
1 /* Diagnostic Client library
2  * Copyright (C) 2024 Avijit Dey
3  *
4  * This Source Code Form is subject to the terms of the Mozilla Public
5  * License, v. 2.0. If a copy of the MPL was not distributed with this
6  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
7  */
8 #ifndef DIAGNOSTIC_CLIENT_LIB_APPL_SRC_DCM_CONFIG_PARSER_CONFIG_PARSER_TYPE_H
9 #define DIAGNOSTIC_CLIENT_LIB_APPL_SRC_DCM_CONFIG_PARSER_CONFIG_PARSER_TYPE_H
10 /* includes */
11 #include <string>
12 
13 #include "parser/json_parser.h"
14 
15 namespace diag {
16 namespace client {
17 namespace config_parser {
18 
19 // Doip network property type
21  // local tcp address
22  std::string tcp_ip_address;
23 };
24 
25 // Properties of a single conversation
27  // store p2 client timeout
28  std::uint16_t p2_client_max;
29  // store p2 star client timeout
30  std::uint16_t p2_star_client_max;
31  // store receive buffer size
32  std::uint16_t rx_buffer_size;
33  // store source address of client
34  std::uint16_t source_address;
35  // store the client conversation name
36  std::string conversation_name;
37  // store the doip network item
39 };
40 
41 // Properties of diag client configuration
43  // local udp address
44  std::string udp_ip_address;
45  // broadcast address
46  std::string udp_broadcast_address;
47  // number of conversation
48  std::uint8_t num_of_conversation;
49  // store all conversations
50  std::vector<ConversationType> conversations;
51 };
52 
60 
61 } // namespace config_parser
62 } // namespace client
63 } // namespace diag
64 #endif // DIAGNOSTIC_CLIENT_LIB_APPL_SRC_DCM_CONFIG_PARSER_CONFIG_PARSER_TYPE_H
boost::property_tree::ptree boost_tree
Type alias for boost property tree.
Definition: json_parser.h:23
diag::client::config_parser::DcmClientConfig ReadDcmClientConfig(boost_support::parser::boost_tree &config_tree)
Function to read from config tree and get the DcmClient configuration.
std::vector< ConversationType > conversations