mirror of
https://github.com/ciphervance/supercell-wx.git
synced 2025-10-30 23:30:04 +00:00
Cell trend data packet
This commit is contained in:
parent
9073ec706b
commit
67a8184ea7
4 changed files with 277 additions and 0 deletions
52
wxdata/include/scwx/wsr88d/rpg/cell_trend_data_packet.hpp
Normal file
52
wxdata/include/scwx/wsr88d/rpg/cell_trend_data_packet.hpp
Normal file
|
|
@ -0,0 +1,52 @@
|
|||
#pragma once
|
||||
|
||||
#include <scwx/wsr88d/rpg/packet.hpp>
|
||||
|
||||
#include <cstdint>
|
||||
#include <memory>
|
||||
|
||||
namespace scwx
|
||||
{
|
||||
namespace wsr88d
|
||||
{
|
||||
namespace rpg
|
||||
{
|
||||
|
||||
class CellTrendDataPacketImpl;
|
||||
|
||||
class CellTrendDataPacket : public Packet
|
||||
{
|
||||
public:
|
||||
explicit CellTrendDataPacket();
|
||||
~CellTrendDataPacket();
|
||||
|
||||
CellTrendDataPacket(const CellTrendDataPacket&) = delete;
|
||||
CellTrendDataPacket& operator=(const CellTrendDataPacket&) = delete;
|
||||
|
||||
CellTrendDataPacket(CellTrendDataPacket&&) noexcept;
|
||||
CellTrendDataPacket& operator=(CellTrendDataPacket&&) noexcept;
|
||||
|
||||
uint16_t packet_code() const;
|
||||
uint16_t length_of_block() const;
|
||||
std::string cell_id() const;
|
||||
int16_t i_position() const;
|
||||
int16_t j_position() const;
|
||||
uint16_t number_of_trends() const;
|
||||
uint16_t trend_code(uint16_t t) const;
|
||||
uint8_t number_of_volumes(uint16_t t) const;
|
||||
uint8_t latest_volume_pointer(uint16_t t) const;
|
||||
uint16_t trend_data(uint16_t t, uint8_t v) const;
|
||||
|
||||
size_t data_size() const override;
|
||||
|
||||
bool Parse(std::istream& is) override;
|
||||
|
||||
static std::shared_ptr<CellTrendDataPacket> Create(std::istream& is);
|
||||
|
||||
private:
|
||||
std::unique_ptr<CellTrendDataPacketImpl> p;
|
||||
};
|
||||
|
||||
} // namespace rpg
|
||||
} // namespace wsr88d
|
||||
} // namespace scwx
|
||||
Loading…
Add table
Add a link
Reference in a new issue