galaxy 1.0.0
Real-Time C++23 Game Programming Framework. Built on data-driven design principles and agile software engineering.
Loading...
Searching...
No Matches
Tag.hpp
Go to the documentation of this file.
1
7
8#ifndef GALAXY_COMPONENTS_TAG_HPP_
9#define GALAXY_COMPONENTS_TAG_HPP_
10
12
13namespace galaxy
14{
15 namespace components
16 {
20 class Tag final : public fs::Serializable
21 {
22 public:
26 Tag();
27
33 Tag(std::string_view tag);
34
40 Tag(const nlohmann::json& json);
41
45 Tag(Tag&&);
46
50 Tag& operator=(Tag&&);
51
55 virtual ~Tag();
56
62 [[nodiscard]]
63 nlohmann::json serialize() override;
64
70 void deserialize(const nlohmann::json& json) override;
71
72 private:
76 Tag& operator=(const Tag&) = delete;
77
81 Tag(const Tag&) = delete;
82
83 public:
87 std::string m_tag;
88 };
89 } // namespace components
90} // namespace galaxy
91
92#endif
Tag an entity.
Definition Tag.hpp:21
Tag(const Tag &)=delete
Copy constructor.
Tag()
Constructor.
Definition Tag.cpp:16
void deserialize(const nlohmann::json &json) override
Deserializes from object.
Definition Tag.cpp:63
std::string m_tag
Tag.
Definition Tag.hpp:87
Tag & operator=(Tag &&)
Move assignment operator.
Definition Tag.cpp:41
Tag & operator=(const Tag &)=delete
Copy assignment operator.
virtual ~Tag()
Destructor.
Definition Tag.cpp:51
nlohmann::json serialize() override
Serializes object.
Definition Tag.cpp:55
Allows a class to be serialized.
Timer.hpp galaxy.
Definition Async.hpp:17