LCOV - code coverage report
Current view: top level - triggeralgs/src - TDMakerSupernovaAlgorithm.cpp (source / functions) Coverage Total Hit
Test: code.result Lines: 0.0 % 13 0
Test Date: 2025-12-21 13:07:08 Functions: 0.0 % 1 0

            Line data    Source code
       1              : /**
       2              :  * @file TDMakerSupernovaAlgorithm.cpp
       3              :  *
       4              :  * This is part of the DUNE DAQ Application Framework, copyright 2020.
       5              :  * Licensing/copyright details are in the COPYING file that you should have
       6              :  * received with this code.
       7              :  */
       8              : 
       9              : #include "triggeralgs/Supernova/TDMakerSupernovaAlgorithm.hpp"
      10              : 
      11              : #include <algorithm>
      12              : #include <chrono>
      13              : #include <limits>
      14              : #include <vector>
      15              : 
      16              : using pd_clock = std::chrono::duration<double, std::ratio<1, 62500000>>;
      17              : using namespace triggeralgs;
      18              : 
      19              : void
      20            0 : TDMakerSupernovaAlgorithm::operator()(const TriggerCandidate& cand, std::vector<TriggerDecision>& decisions)
      21              : {
      22              : 
      23            0 :   std::vector<TriggerCandidate> vCand;
      24            0 :   vCand.push_back(cand);
      25              : 
      26            0 :   auto now = std::chrono::steady_clock::now();
      27              :   //  Timestamp
      28            0 :   uint32_t algorithm = (uint32_t)pd_clock(now.time_since_epoch()).count(); // NOLINT(build/unsigned)
      29              : 
      30            0 :   TriggerDecision trigger{ cand.time_start,
      31            0 :                            cand.time_end,
      32            0 :                            cand.time_candidate,
      33              :                            0,
      34              :                            0,
      35              :                            0,
      36              :                            // cand.detid,
      37              :                            0,
      38              :                            algorithm,
      39            0 :                            cand.version,
      40            0 :                            vCand };
      41              : 
      42              :   // Give the trigger word back
      43            0 :   decisions.push_back(trigger);
      44            0 :   return;
      45            0 : }
        

Generated by: LCOV version 2.0-1