• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /**
2  * Copyright (c) 2022-2024 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef PANDA_TOOLING_INSPECTOR_CONNECTION_ASIO_ASIO_CONFIG_H
17 #define PANDA_TOOLING_INSPECTOR_CONNECTION_ASIO_ASIO_CONFIG_H
18 
19 #include "websocketpp/config/asio_no_tls.hpp"
20 #include "websocketpp/logger/levels.hpp"
21 #include "websocketpp/transport/asio/endpoint.hpp"
22 
23 #include "connection/asio/ws_logger.h"
24 
25 namespace ark::tooling::inspector {
26 // NOLINTBEGIN(readability-identifier-naming)
27 struct AsioConfig : websocketpp::config::asio {
28     static const websocketpp::log::level alog_level = websocketpp::log::alevel::access_core;
29 
30     using alog_type = WsLogger;
31     using elog_type = WsLogger;
32 
33     struct transport_config : websocketpp::config::asio::transport_config {
34         using alog_type = AsioConfig::alog_type;
35         using elog_type = AsioConfig::elog_type;
36     };
37 
38     using transport_type = websocketpp::transport::asio::endpoint<transport_config>;
39 };
40 // NOLINTEND(readability-identifier-naming)
41 }  // namespace ark::tooling::inspector
42 
43 #endif  // PANDA_TOOLING_INSPECTOR_CONNECTION_ASIO_ASIO_CONFIG_H
44