TrinityCore
Loading...
Searching...
No Matches
Ticket Class Referenceabstract

#include <SupportMgr.h>

+ Inheritance diagram for Ticket:

Public Member Functions

 Ticket ()
 
 Ticket (Player *player)
 
 Ticket (Ticket const &)=delete
 
 Ticket (Ticket &&)=delete
 
Ticket & operator= (Ticket const &)=delete
 
Ticket & operator= (Ticket &&)=delete
 
virtual ~Ticket ()
 
bool IsClosed () const
 
bool IsFromPlayer (ObjectGuid guid) const
 
bool IsAssigned () const
 
bool IsAssignedTo (ObjectGuid guid) const
 
bool IsAssignedNotTo (ObjectGuid guid) const
 
uint32 GetId () const
 
ObjectGuid GetPlayerGuid () const
 
Player * GetPlayer () const
 
std::string GetPlayerName () const
 
Player * GetAssignedPlayer () const
 
ObjectGuid GetAssignedToGUID () const
 
std::string GetAssignedToName () const
 
std::string const & GetComment () const
 
virtual void SetAssignedTo (ObjectGuid guid, bool=false)
 
virtual void SetUnassigned ()
 
void SetClosedBy (ObjectGuid value)
 
void SetComment (std::string const &comment)
 
void SetPosition (uint32 mapId, Position const &pos)
 
void SetFacing (float facing)
 
virtual void LoadFromDB (Field *fields)=0
 
virtual void SaveToDB () const =0
 
virtual void DeleteFromDB ()=0
 
void TeleportTo (Player *player) const
 
virtual std::string FormatViewMessageString (ChatHandler &handler, bool detailed=false) const =0
 
virtual std::string FormatViewMessageString (ChatHandler &handler, const char *szClosedName, const char *szAssignedToName, const char *szUnassignedName, const char *szDeletedName) const
 

Protected Attributes

uint32 _id
 
ObjectGuid _playerGuid
 
uint16 _mapId
 
Position _pos
 
uint64 _createTime
 
ObjectGuid _closedBy
 
ObjectGuid _assignedTo
 
std::string _comment
 

Detailed Description

Definition at line 97 of file SupportMgr.h.

Constructor & Destructor Documentation

◆ Ticket() [1/4]

Ticket::Ticket ( )

Definition at line 33 of file SupportMgr.cpp.

◆ Ticket() [2/4]

Ticket::Ticket ( Player *  player)

Definition at line 35 of file SupportMgr.cpp.

References _playerGuid, and BaseEntity::GetGUID().

◆ Ticket() [3/4]

Ticket::Ticket ( Ticket const &  )
delete

◆ Ticket() [4/4]

Ticket::Ticket ( Ticket &&  )
delete

◆ ~Ticket()

Ticket::~Ticket ( )
virtual

Definition at line 40 of file SupportMgr.cpp.

Member Function Documentation

◆ DeleteFromDB()

virtual void Ticket::DeleteFromDB ( )
pure virtual

◆ FormatViewMessageString() [1/2]

virtual std::string Ticket::FormatViewMessageString ( ChatHandler &  handler,
bool  detailed = false 
) const
pure virtual

◆ FormatViewMessageString() [2/2]

std::string Ticket::FormatViewMessageString ( ChatHandler &  handler,
const char *  szClosedName,
const char *  szAssignedToName,
const char *  szUnassignedName,
const char *  szDeletedName 
) const
virtual

◆ GetAssignedPlayer()

Player * Ticket::GetAssignedPlayer ( ) const

Definition at line 56 of file SupportMgr.cpp.

References _assignedTo, and ObjectAccessor::FindConnectedPlayer().

◆ GetAssignedToGUID()

ObjectGuid Ticket::GetAssignedToGUID ( ) const
inline

Definition at line 119 of file SupportMgr.h.

◆ GetAssignedToName()

std::string Ticket::GetAssignedToName ( ) const

◆ GetComment()

std::string const & Ticket::GetComment ( ) const
inline

Definition at line 121 of file SupportMgr.h.

◆ GetId()

◆ GetPlayer()

Player * Ticket::GetPlayer ( ) const

Definition at line 42 of file SupportMgr.cpp.

References _playerGuid, and ObjectAccessor::FindConnectedPlayer().

◆ GetPlayerGuid()

ObjectGuid Ticket::GetPlayerGuid ( ) const
inline

Definition at line 115 of file SupportMgr.h.

◆ GetPlayerName()

◆ IsAssigned()

bool Ticket::IsAssigned ( ) const
inline

Definition at line 110 of file SupportMgr.h.

◆ IsAssignedNotTo()

bool Ticket::IsAssignedNotTo ( ObjectGuid  guid) const
inline

Definition at line 112 of file SupportMgr.h.

◆ IsAssignedTo()

bool Ticket::IsAssignedTo ( ObjectGuid  guid) const
inline

Definition at line 111 of file SupportMgr.h.

◆ IsClosed()

◆ IsFromPlayer()

bool Ticket::IsFromPlayer ( ObjectGuid  guid) const
inline

Definition at line 109 of file SupportMgr.h.

◆ LoadFromDB()

virtual void Ticket::LoadFromDB ( Field *  fields)
pure virtual

◆ operator=() [1/2]

Ticket & Ticket::operator= ( Ticket &&  )
delete

◆ operator=() [2/2]

Ticket & Ticket::operator= ( Ticket const &  )
delete

◆ SaveToDB()

virtual void Ticket::SaveToDB ( ) const
pure virtual

◆ SetAssignedTo()

virtual void Ticket::SetAssignedTo ( ObjectGuid  guid,
bool  = false 
)
inlinevirtual

Definition at line 123 of file SupportMgr.h.

◆ SetClosedBy()

void Ticket::SetClosedBy ( ObjectGuid  value)
inline

Definition at line 125 of file SupportMgr.h.

◆ SetComment()

void Ticket::SetComment ( std::string const &  comment)
inline

Definition at line 126 of file SupportMgr.h.

◆ SetFacing()

void Ticket::SetFacing ( float  facing)
inline

◆ SetPosition()

void Ticket::SetPosition ( uint32  mapId,
Position const &  pos 
)
inline

◆ SetUnassigned()

virtual void Ticket::SetUnassigned ( )
inlinevirtual

Definition at line 124 of file SupportMgr.h.

◆ TeleportTo()

void Ticket::TeleportTo ( Player *  player) const

Member Data Documentation

◆ _assignedTo

◆ _closedBy

◆ _comment

◆ _createTime

◆ _id

◆ _mapId

◆ _playerGuid

◆ _pos


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