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
galaxy::components::Tag Class Referencefinal

Tag an entity. More...

#include <Tag.hpp>

+ Inheritance diagram for galaxy::components::Tag:
+ Collaboration diagram for galaxy::components::Tag:

Public Member Functions

 Tag ()
 Constructor.
 
 Tag (std::string_view tag)
 Constructor.
 
 Tag (const nlohmann::json &json)
 JSON constructor.
 
 Tag (Tag &&)
 Move constructor.
 
Tagoperator= (Tag &&)
 Move assignment operator.
 
virtual ~Tag ()
 Destructor.
 
nlohmann::json serialize () override
 Serializes object.
 
void deserialize (const nlohmann::json &json) override
 Deserializes from object.
 
- Public Member Functions inherited from galaxy::fs::Serializable
virtual ~Serializable ()
 Destructor.
 
virtual Serializableoperator= (Serializable &&)=default
 Move assignment operator.
 
virtual Serializableoperator= (const Serializable &)=default
 Copy assignment operator.
 

Public Attributes

std::string m_tag
 Tag.
 

Private Member Functions

Tagoperator= (const Tag &)=delete
 Copy assignment operator.
 
 Tag (const Tag &)=delete
 Copy constructor.
 

Additional Inherited Members

- Protected Member Functions inherited from galaxy::fs::Serializable
 Serializable ()
 Constructor.
 

Detailed Description

Tag an entity.

Definition at line 20 of file Tag.hpp.

Constructor & Destructor Documentation

◆ Tag() [1/5]

galaxy::components::Tag::Tag ( )

Constructor.

Definition at line 16 of file Tag.cpp.

◆ Tag() [2/5]

galaxy::components::Tag::Tag ( std::string_view tag)

Constructor.

Parameters
tagTag for entity.

Definition at line 22 of file Tag.cpp.

◆ Tag() [3/5]

galaxy::components::Tag::Tag ( const nlohmann::json & json)

JSON constructor.

Parameters
jsonJSON defining object.

Definition at line 28 of file Tag.cpp.

+ Here is the call graph for this function:

◆ Tag() [4/5]

galaxy::components::Tag::Tag ( Tag && t)

Move constructor.

Definition at line 34 of file Tag.cpp.

◆ ~Tag()

galaxy::components::Tag::~Tag ( )
virtual

Destructor.

Definition at line 51 of file Tag.cpp.

◆ Tag() [5/5]

galaxy::components::Tag::Tag ( const Tag & )
privatedelete

Copy constructor.

Member Function Documentation

◆ operator=() [1/2]

Tag & galaxy::components::Tag::operator= ( Tag && t)

Move assignment operator.

Definition at line 41 of file Tag.cpp.

◆ serialize()

nlohmann::json galaxy::components::Tag::serialize ( )
nodiscardoverridevirtual

Serializes object.

Returns
JSON object containing data to be serialized.

Implements galaxy::fs::Serializable.

Definition at line 55 of file Tag.cpp.

◆ deserialize()

void galaxy::components::Tag::deserialize ( const nlohmann::json & json)
overridevirtual

Deserializes from object.

Parameters
jsonJson object to retrieve data from.

Implements galaxy::fs::Serializable.

Definition at line 63 of file Tag.cpp.

+ Here is the caller graph for this function:

◆ operator=() [2/2]

Tag & galaxy::components::Tag::operator= ( const Tag & )
privatedelete

Copy assignment operator.

Member Data Documentation

◆ m_tag

std::string galaxy::components::Tag::m_tag

Tag.

Definition at line 87 of file Tag.hpp.


The documentation for this class was generated from the following files: