LCOV - code coverage report
Current view: top level - engine/input/keyboard - action.hpp (source / functions) Coverage Total Hit
Test: coverage.info Lines: 100.0 % 10 10
Test Date: 2026-03-11 04:45:14 Functions: 100.0 % 1 1

            Line data    Source code
       1              : #pragma once
       2              : 
       3              : #include <cstdint>
       4              : #include <string_view>
       5              : 
       6              : namespace jage::engine::input::keyboard {
       7              : enum class action : std::uint8_t {
       8              :   release,
       9              :   press,
      10              :   repeat,
      11              : };
      12              : 
      13              : [[nodiscard]] constexpr auto
      14           11 : serialize(const action input_action) -> std::string_view {
      15           11 :   switch (input_action) {
      16            4 :   case action::release:
      17            4 :     return "release";
      18            3 :   case action::press:
      19            3 :     return "press";
      20            2 :   case action::repeat:
      21            2 :     return "repeat";
      22            2 :   default:
      23            2 :     return "unknown enumerator";
      24              :   }
      25              : }
      26              : 
      27              : } // namespace jage::engine::input::keyboard
        

Generated by: LCOV version 2.0-1