RPG clang-tidy cleanup

This commit is contained in:
Dan Paulat 2025-05-17 00:18:07 -05:00
parent e49adafda9
commit 68a5baa5c4
6 changed files with 223 additions and 204 deletions

View file

@ -9,22 +9,17 @@
#include <scwx/wsr88d/rpg/tabular_product_message.hpp>
#include <unordered_map>
#include <vector>
namespace scwx
{
namespace wsr88d
{
namespace rpg
namespace scwx::wsr88d::rpg
{
static const std::string logPrefix_ =
"scwx::wsr88d::rpg::level3_message_factory";
static const auto logger_ = util::Logger::Create(logPrefix_);
typedef std::function<std::shared_ptr<Level3Message>(Level3MessageHeader&&,
std::istream&)>
CreateLevel3MessageFunction;
using CreateLevel3MessageFunction =
std::function<std::shared_ptr<Level3Message>(Level3MessageHeader&&,
std::istream&)>;
static const std::unordered_map<int, CreateLevel3MessageFunction> //
create_ {{2, GeneralStatusMessage::Create},
@ -154,13 +149,12 @@ std::shared_ptr<Level3Message> Level3MessageFactory::Create(std::istream& is)
else if (headerValid)
{
// Seek to the end of the current message
is.seekg(header.length_of_message() - Level3MessageHeader::SIZE,
is.seekg(static_cast<std::streamoff>(header.length_of_message()) -
static_cast<std::streamoff>(Level3MessageHeader::SIZE),
std::ios_base::cur);
}
return message;
}
} // namespace rpg
} // namespace wsr88d
} // namespace scwx
} // namespace scwx::wsr88d::rpg