TrinityCore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
WorldPackets::Chat::ChatRegisterAddonPrefixes Class Referencefinal

#include <ChatPackets.h>

Public Types

enum  { MAX_PREFIXES = 64 }
 

Public Member Functions

 ChatRegisterAddonPrefixes (WorldPacket &&packet)
 
void Read () override
 
- Public Member Functions inherited from WorldPackets::ClientPacket
 ClientPacket (WorldPacket &&packet)
 
 ClientPacket (OpcodeClient expectedOpcode, WorldPacket &&packet)
 
WorldPacket constWrite () overridefinal
 
OpcodeClient GetOpcode () const
 
- Public Member Functions inherited from WorldPackets::Packet
 Packet (WorldPacket &&worldPacket)
 
virtual ~Packet ()=default
 
 Packet (Packet const &right)=delete
 
Packetoperator= (Packet const &right)=delete
 
WorldPacket constGetRawPacket () const
 
size_t GetSize () const
 
ConnectionType GetConnection () const
 

Public Attributes

Array< std::string, MAX_PREFIXESPrefixes
 

Additional Inherited Members

- Protected Attributes inherited from WorldPackets::Packet
WorldPacket _worldPacket
 

Member Enumeration Documentation

anonymous enum
Enumerator
MAX_PREFIXES 
263  {
264  MAX_PREFIXES = 64
265  };

Constructor & Destructor Documentation

WorldPackets::Chat::ChatRegisterAddonPrefixes::ChatRegisterAddonPrefixes ( WorldPacket &&  packet)
inline
267 : ClientPacket(CMSG_CHAT_REGISTER_ADDON_PREFIXES, std::move(packet)) { }
Definition: Opcodes.h:208
ClientPacket(WorldPacket &&packet)
Definition: Packet.h:62

Member Function Documentation

void WorldPackets::Chat::ChatRegisterAddonPrefixes::Read ( )
overridevirtual

Implements WorldPackets::Packet.

253 {
255  for (std::string& prefix : Prefixes)
256  prefix.assign(_worldPacket.ReadString(_worldPacket.ReadBits(5)));
257 }
uint32 ReadBits(int32 bits)
Definition: ByteBuffer.h:204
WorldPacket _worldPacket
Definition: Packet.h:43
std::string ReadString(uint32 length)
Definition: ByteBuffer.h:524
uint32_t uint32
Definition: Define.h:150
void resize(size_type newSize)
Definition: PacketUtilities.h:95
Array< std::string, MAX_PREFIXES > Prefixes
Definition: ChatPackets.h:271
T read()
Definition: ByteBuffer.h:484

Member Data Documentation

Array<std::string, MAX_PREFIXES> WorldPackets::Chat::ChatRegisterAddonPrefixes::Prefixes

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