LCOV - code coverage report
Current view: top level - detchannelmaps/plugins - SimplePDSChannelMap.cpp (source / functions) Coverage Total Hit
Test: code.result Lines: 0.0 % 13 0
Test Date: 2026-10-11 15:05:20 Functions: 0.0 % 6 0

            Line data    Source code
       1              : #include "detchannelmaps/PDSChannelMap.hpp"
       2              : 
       3              : #include "logging/Logging.hpp" // NOLINT
       4              : 
       5              : #include <format>
       6              : 
       7              : namespace dunedaq {
       8              : namespace detchannelmaps {
       9              : 
      10              : class SimplePDSChannelMap : public PDSChannelMap
      11              : {
      12              : public:
      13            0 :   explicit SimplePDSChannelMap() {}
      14              : 
      15              :   SimplePDSChannelMap(const SimplePDSChannelMap&) = delete; ///< SimplePDSChannelMap is not copy-constructible
      16              :   SimplePDSChannelMap& operator=(const SimplePDSChannelMap&) = delete; ///< SimplePDSChannelMap is not copy-assignable
      17              :   SimplePDSChannelMap(SimplePDSChannelMap&&) = delete;            ///< SimplePDSChannelMap is not move-constructible
      18              :   SimplePDSChannelMap& operator=(SimplePDSChannelMap&&) = delete; ///< SimplePDSChannelMap is not move-assignable
      19              : 
      20            0 :   uint get_offline_channel_from_det_crate_slot_stream_chan(uint, // det
      21              :                                                            uint, // crate
      22              :                                                            uint slot,
      23              :                                                            uint, // stream
      24              :                                                            uint channel) final
      25              :   {
      26            0 :     return slot * 100 + channel;
      27              :   }
      28              : 
      29            0 :   std::optional<PDSChannelInfo> get_det_crate_slot_fiber_chan_from_offline_channel(uint offchannel) final
      30              :   {
      31              : 
      32            0 :     PDSChannelInfo pds_ch_info;
      33            0 :     pds_ch_info.channel = offchannel % 100;
      34            0 :     pds_ch_info.slot = offchannel / 100;
      35            0 :     pds_ch_info.element = offchannel / 100;
      36              : 
      37            0 :     return pds_ch_info;
      38              :   }
      39              : 
      40            0 :   uint get_element_from_offline_channel(uint offchannel) final { return offchannel / 100; }
      41              : 
      42            0 :   std::string get_element_name_from_offline_channel(uint offchannel) final
      43              :   {
      44            0 :     return std::format("PDSModule{}", offchannel / 100);
      45              :   }
      46              : };
      47              : 
      48            0 : DEFINE_DUNE_DET_PDSCHANNEL_MAP(dunedaq::detchannelmaps::SimplePDSChannelMap)
      49              : 
      50              : } // namespace detchannelmaps
      51              : } // namespace dunedaq
        

Generated by: LCOV version 2.0-1