LCOV - code coverage report
Current view: top level - generated/src/ad/rss/state - UnstructuredSceneResponse.cpp (source / functions) Hit Total Coverage
Test: ad_rss Lines: 30 30 100.0 %
Date: 2024-04-23 14:35:54 Functions: 2 2 100.0 %
Branches: 5 5 100.0 %

           Branch data     Line data    Source code
       1                 :            : /*
       2                 :            :  * ----------------- BEGIN LICENSE BLOCK ---------------------------------
       3                 :            :  *
       4                 :            :  * Copyright (C) 2018-2020 Intel Corporation
       5                 :            :  *
       6                 :            :  * SPDX-License-Identifier: LGPL-2.1-only
       7                 :            :  *
       8                 :            :  * ----------------- END LICENSE BLOCK -----------------------------------
       9                 :            :  */
      10                 :            : 
      11                 :            : /**
      12                 :            :  * Generated file
      13                 :            :  * @file
      14                 :            :  *
      15                 :            :  * Generator Version : 11.0.0-1997
      16                 :            :  */
      17                 :            : 
      18                 :            : #include "ad/rss/state/UnstructuredSceneResponse.hpp"
      19                 :            : #include <stdexcept>
      20                 :            : 
      21                 :    1015880 : std::string toString(::ad::rss::state::UnstructuredSceneResponse const e)
      22                 :            : {
      23   [ +  +  +  +  :    1015880 :   switch (e)
                      + ]
      24                 :            :   {
      25                 :       1067 :     case ::ad::rss::state::UnstructuredSceneResponse::None:
      26                 :       1067 :       return std::string("::ad::rss::state::UnstructuredSceneResponse::None"); // LCOV_EXCL_BR_LINE
      27                 :          1 :     case ::ad::rss::state::UnstructuredSceneResponse::ContinueForward:
      28                 :          1 :       return std::string("::ad::rss::state::UnstructuredSceneResponse::ContinueForward"); // LCOV_EXCL_BR_LINE
      29                 :          1 :     case ::ad::rss::state::UnstructuredSceneResponse::DriveAway:
      30                 :          1 :       return std::string("::ad::rss::state::UnstructuredSceneResponse::DriveAway"); // LCOV_EXCL_BR_LINE
      31                 :      14784 :     case ::ad::rss::state::UnstructuredSceneResponse::Brake:
      32                 :      14784 :       return std::string("::ad::rss::state::UnstructuredSceneResponse::Brake"); // LCOV_EXCL_BR_LINE
      33                 :    1000030 :     default:
      34                 :    1000030 :       return std::string("UNKNOWN ENUM VALUE"); // LCOV_EXCL_BR_LINE
      35                 :            :   }
      36                 :            : }
      37                 :            : 
      38                 :          9 : template <>::ad::rss::state::UnstructuredSceneResponse fromString(std::string const &str)
      39                 :            : {
      40                 :          9 :   if (str == std::string("::ad::rss::state::UnstructuredSceneResponse::None")) // LCOV_EXCL_BR_LINE
      41                 :            :   {
      42                 :          1 :     return ::ad::rss::state::UnstructuredSceneResponse::None;
      43                 :            :   }
      44                 :          8 :   if (str == std::string("None")) // LCOV_EXCL_BR_LINE
      45                 :            :   {
      46                 :          1 :     return ::ad::rss::state::UnstructuredSceneResponse::None;
      47                 :            :   }
      48                 :          7 :   if (str == std::string("::ad::rss::state::UnstructuredSceneResponse::ContinueForward")) // LCOV_EXCL_BR_LINE
      49                 :            :   {
      50                 :          1 :     return ::ad::rss::state::UnstructuredSceneResponse::ContinueForward;
      51                 :            :   }
      52                 :          6 :   if (str == std::string("ContinueForward")) // LCOV_EXCL_BR_LINE
      53                 :            :   {
      54                 :          1 :     return ::ad::rss::state::UnstructuredSceneResponse::ContinueForward;
      55                 :            :   }
      56                 :          5 :   if (str == std::string("::ad::rss::state::UnstructuredSceneResponse::DriveAway")) // LCOV_EXCL_BR_LINE
      57                 :            :   {
      58                 :          1 :     return ::ad::rss::state::UnstructuredSceneResponse::DriveAway;
      59                 :            :   }
      60                 :          4 :   if (str == std::string("DriveAway")) // LCOV_EXCL_BR_LINE
      61                 :            :   {
      62                 :          1 :     return ::ad::rss::state::UnstructuredSceneResponse::DriveAway;
      63                 :            :   }
      64                 :          3 :   if (str == std::string("::ad::rss::state::UnstructuredSceneResponse::Brake")) // LCOV_EXCL_BR_LINE
      65                 :            :   {
      66                 :          1 :     return ::ad::rss::state::UnstructuredSceneResponse::Brake;
      67                 :            :   }
      68                 :          2 :   if (str == std::string("Brake")) // LCOV_EXCL_BR_LINE
      69                 :            :   {
      70                 :          1 :     return ::ad::rss::state::UnstructuredSceneResponse::Brake;
      71                 :            :   }
      72                 :          1 :   throw std::out_of_range("Invalid enum literal"); // LCOV_EXCL_BR_LINE
      73                 :            : }

Generated by: LCOV version 1.14