LCOV - code coverage report
Current view: top level - generated/include/ad/map/access - MapMetaData.hpp (source / functions) Hit Total Coverage
Test: ad_map_access Lines: 14 14 100.0 %
Date: 2022-10-04 09:48:07 Functions: 4 4 100.0 %
Branches: 3 6 50.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: MIT
       7                 :            :  *
       8                 :            :  * ----------------- END LICENSE BLOCK -----------------------------------
       9                 :            :  */
      10                 :            : 
      11                 :            : /**
      12                 :            :  * Generated file
      13                 :            :  * @file
      14                 :            :  *
      15                 :            :  * Generator Version : 11.0.0-1997
      16                 :            :  */
      17                 :            : 
      18                 :            : #pragma once
      19                 :            : 
      20                 :            : #include <iostream>
      21                 :            : #include <memory>
      22                 :            : #include <sstream>
      23                 :            : #include "ad/map/access/TrafficType.hpp"
      24                 :            : /*!
      25                 :            :  * @brief namespace ad
      26                 :            :  */
      27                 :            : namespace ad {
      28                 :            : /*!
      29                 :            :  * @brief namespace map
      30                 :            :  */
      31                 :            : namespace map {
      32                 :            : /*!
      33                 :            :  * @brief namespace access
      34                 :            :  *
      35                 :            :  * Accessing map data
      36                 :            :  */
      37                 :            : namespace access {
      38                 :            : 
      39                 :            : /*!
      40                 :            :  * \brief DataType MapMetaData
      41                 :            :  *
      42                 :            :  * Meta data specific to a map
      43                 :            :  */
      44                 :            : struct MapMetaData
      45                 :            : {
      46                 :            :   /*!
      47                 :            :    * \brief Smart pointer on MapMetaData
      48                 :            :    */
      49                 :            :   typedef std::shared_ptr<MapMetaData> Ptr;
      50                 :            : 
      51                 :            :   /*!
      52                 :            :    * \brief Smart pointer on constant MapMetaData
      53                 :            :    */
      54                 :            :   typedef std::shared_ptr<MapMetaData const> ConstPtr;
      55                 :            : 
      56                 :            :   /*!
      57                 :            :    * \brief standard constructor
      58                 :            :    */
      59                 :            :   MapMetaData() = default;
      60                 :            : 
      61                 :            :   /*!
      62                 :            :    * \brief standard destructor
      63                 :            :    */
      64                 :            :   ~MapMetaData() = default;
      65                 :            : 
      66                 :            :   /*!
      67                 :            :    * \brief standard copy constructor
      68                 :            :    */
      69                 :            :   MapMetaData(const MapMetaData &other) = default;
      70                 :            : 
      71                 :            :   /*!
      72                 :            :    * \brief standard move constructor
      73                 :            :    */
      74                 :            :   MapMetaData(MapMetaData &&other) = default;
      75                 :            : 
      76                 :            :   /**
      77                 :            :    * \brief standard assignment operator
      78                 :            :    *
      79                 :            :    * \param[in] other Other MapMetaData
      80                 :            :    *
      81                 :            :    * \returns Reference to this MapMetaData.
      82                 :            :    */
      83                 :            :   MapMetaData &operator=(const MapMetaData &other) = default;
      84                 :            : 
      85                 :            :   /**
      86                 :            :    * \brief standard move operator
      87                 :            :    *
      88                 :            :    * \param[in] other Other MapMetaData
      89                 :            :    *
      90                 :            :    * \returns Reference to this MapMetaData.
      91                 :            :    */
      92                 :            :   MapMetaData &operator=(MapMetaData &&other) = default;
      93                 :            : 
      94                 :            :   /**
      95                 :            :    * \brief standard comparison operator
      96                 :            :    *
      97                 :            :    * \param[in] other Other MapMetaData
      98                 :            :    *
      99                 :            :    * \returns \c true if both MapMetaData are equal
     100                 :            :    */
     101                 :          9 :   bool operator==(const MapMetaData &other) const
     102                 :            :   {
     103                 :          9 :     return (trafficType == other.trafficType);
     104                 :            :   }
     105                 :            : 
     106                 :            :   /**
     107                 :            :    * \brief standard comparison operator
     108                 :            :    *
     109                 :            :    * \param[in] other Other MapMetaData.
     110                 :            :    *
     111                 :            :    * \returns \c true if both MapMetaData are different
     112                 :            :    */
     113                 :          2 :   bool operator!=(const MapMetaData &other) const
     114                 :            :   {
     115                 :          2 :     return !operator==(other);
     116                 :            :   }
     117                 :            : 
     118                 :            :   ::ad::map::access::TrafficType trafficType;
     119                 :            : };
     120                 :            : 
     121                 :            : } // namespace access
     122                 :            : } // namespace map
     123                 :            : } // namespace ad
     124                 :            : 
     125                 :            : /*!
     126                 :            :  * \brief protect the definition of functions from duplicates by typedef usage within other data types
     127                 :            :  */
     128                 :            : #ifndef GEN_GUARD_AD_MAP_ACCESS_MAPMETADATA
     129                 :            : #define GEN_GUARD_AD_MAP_ACCESS_MAPMETADATA
     130                 :            : /*!
     131                 :            :  * @brief namespace ad
     132                 :            :  */
     133                 :            : namespace ad {
     134                 :            : /*!
     135                 :            :  * @brief namespace map
     136                 :            :  */
     137                 :            : namespace map {
     138                 :            : /*!
     139                 :            :  * @brief namespace access
     140                 :            :  *
     141                 :            :  * Accessing map data
     142                 :            :  */
     143                 :            : namespace access {
     144                 :            : 
     145                 :            : /**
     146                 :            :  * \brief standard ostream operator
     147                 :            :  *
     148                 :            :  * \param[in] os The output stream to write to
     149                 :            :  * \param[in] _value MapMetaData value
     150                 :            :  *
     151                 :            :  * \returns The stream object.
     152                 :            :  *
     153                 :            :  */
     154                 :          6 : inline std::ostream &operator<<(std::ostream &os, MapMetaData const &_value)
     155                 :            : {
     156                 :          6 :   os << "MapMetaData(";
     157                 :          6 :   os << "trafficType:";
     158                 :          6 :   os << _value.trafficType;
     159                 :          6 :   os << ")";
     160                 :          6 :   return os;
     161                 :            : }
     162                 :            : 
     163                 :            : } // namespace access
     164                 :            : } // namespace map
     165                 :            : } // namespace ad
     166                 :            : 
     167                 :            : namespace std {
     168                 :            : /*!
     169                 :            :  * \brief overload of the std::to_string for MapMetaData
     170                 :            :  */
     171                 :          1 : inline std::string to_string(::ad::map::access::MapMetaData const &value)
     172                 :            : {
     173         [ +  - ]:          2 :   stringstream sstream;
     174         [ +  - ]:          1 :   sstream << value;
     175         [ +  - ]:          2 :   return sstream.str();
     176                 :            : }
     177                 :            : } // namespace std
     178                 :            : #endif // GEN_GUARD_AD_MAP_ACCESS_MAPMETADATA

Generated by: LCOV version 1.14