Use strings instead of character arrays where warranted

This commit is contained in:
Dan Paulat 2022-01-12 00:41:08 -06:00
parent 798b348d8b
commit 09649c0fe7
4 changed files with 36 additions and 14 deletions

View file

@ -4,6 +4,7 @@
#include <cstdint>
#include <memory>
#include <string>
namespace scwx
{
@ -26,9 +27,9 @@ public:
StormIdSymbolPacket(StormIdSymbolPacket&&) noexcept;
StormIdSymbolPacket& operator=(StormIdSymbolPacket&&) noexcept;
int16_t i_position(size_t i) const;
int16_t j_position(size_t i) const;
const std::array<char, 2>& character(size_t i) const;
int16_t i_position(size_t i) const;
int16_t j_position(size_t i) const;
std::string storm_id(size_t i) const;
size_t RecordCount() const override;

View file

@ -4,6 +4,7 @@
#include <cstdint>
#include <memory>
#include <string>
namespace scwx
{
@ -30,6 +31,9 @@ public:
uint16_t packet_code() const;
uint16_t length_of_block() const;
std::optional<uint16_t> value_of_text() const;
int16_t start_i() const;
int16_t start_j() const;
std::string text() const;
size_t data_size() const override;