ad_rss_map_integration
RssConstellationCreationModeValidInputRange.hpp
Go to the documentation of this file.
1 /*
2  * ----------------- BEGIN LICENSE BLOCK ---------------------------------
3  *
4  * Copyright (C) 2018-2022 Intel Corporation
5  *
6  * SPDX-License-Identifier: LGPL-2.1-only
7  *
8  * ----------------- END LICENSE BLOCK -----------------------------------
9  */
10 
18 #pragma once
19 
20 #include <cmath>
21 #include <limits>
23 #include "spdlog/fmt/ostr.h"
24 #include "spdlog/spdlog.h"
25 
37  bool const logErrors = true)
38 {
39  bool inValidInputRange = (input == ::ad::rss::map::RssConstellationCreationMode::Ignore)
41  || (input == ::ad::rss::map::RssConstellationCreationMode::Structured)
43  if (!inValidInputRange && logErrors)
44  {
45  spdlog::error("withinValidInputRange(::ad::rss::map::RssConstellationCreationMode)>> {}, raw value: {} ",
46  input,
47  static_cast<int32_t>(input)); // LCOV_EXCL_BR_LINE
48  }
49  return inValidInputRange;
50 }
bool withinValidInputRange(::ad::rss::map::RssConstellationCreationMode const &input, bool const logErrors=true)
check if the given RssConstellationCreationMode is within valid input range
Definition: RssConstellationCreationModeValidInputRange.hpp:36
RssConstellationCreationMode
DataType RssConstellationCreationMode.
Definition: RssConstellationCreationMode.hpp:44