LCOV - code coverage report
Current view: top level - wirestead/transport/uds/detail - reconnect_decider.hpp (source / functions) Coverage Total Hit
Test: Wirestead Coverage Report Lines: 100.0 % 2 2
Test Date: 2026-08-30 10:35:09 Functions: 100.0 % 1 1
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: - 0 0

             Branch data     Line data    Source code
       1                 :             : /*
       2                 :             :  * Copyright 2025 Jinwoo Sung
       3                 :             :  *
       4                 :             :  * Licensed under the Apache License, Version 2.0 (the "License");
       5                 :             :  * you may not use this file except in compliance with the License.
       6                 :             :  * You may obtain a copy of the License at
       7                 :             :  *
       8                 :             :  *     http://www.apache.org/licenses/LICENSE-2.0
       9                 :             :  *
      10                 :             :  * Unless required by applicable law or agreed to in writing, software
      11                 :             :  * distributed under the License is distributed on an "AS IS" BASIS,
      12                 :             :  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
      13                 :             :  * See the License for the specific language governing permissions and
      14                 :             :  * limitations under the License.
      15                 :             :  */
      16                 :             : 
      17                 :             : #pragma once
      18                 :             : 
      19                 :             : #include "wirestead/config/uds_config.hpp"
      20                 :             : #include "wirestead/transport/base/reconnect_decider.hpp"
      21                 :             : 
      22                 :             : namespace wirestead {
      23                 :             : namespace transport {
      24                 :             : namespace detail {
      25                 :             : 
      26                 :             : /**
      27                 :             :  * @brief Represents the decision on whether to retry a connection attempt for UDS.
      28                 :             :  */
      29                 :             : using UdsReconnectLogicDecision = ReconnectLogicDecision;
      30                 :             : 
      31                 :             : /**
      32                 :             :  * @brief Determines whether a UDS reconnection attempt should be made.
      33                 :             :  */
      34                 :           8 : inline UdsReconnectLogicDecision decide_reconnect_uds(const config::UdsClientConfig& cfg,
      35                 :             :                                                       const diagnostics::ErrorInfo& error_info, uint32_t attempt_count,
      36                 :             :                                                       const std::optional<ReconnectPolicy>& policy) {
      37                 :           8 :   return decide_reconnect_common(cfg, error_info, attempt_count, policy);
      38                 :             : }
      39                 :             : 
      40                 :             : }  // namespace detail
      41                 :             : }  // namespace transport
      42                 :             : }  // namespace wirestead
        

Generated by: LCOV version 2.0-1