TrinityCore
lfg::LFGQueue Class Reference

#include <LFGQueue.h>

Public Member Functions

std::string GetDetailedMatchRoles (GuidList const &check) const
 
void AddToQueue (ObjectGuid guid, bool reAdd=false)
 
void RemoveFromQueue (ObjectGuid guid)
 
void AddQueueData (ObjectGuid guid, time_t joinTime, LfgDungeonSet const &dungeons, LfgRolesMap const &rolesMap)
 
void RemoveQueueData (ObjectGuid guid)
 
void UpdateWaitTimeAvg (int32 waitTime, uint32 dungeonId)
 
void UpdateWaitTimeTank (int32 waitTime, uint32 dungeonId)
 
void UpdateWaitTimeHealer (int32 waitTime, uint32 dungeonId)
 
void UpdateWaitTimeDps (int32 waitTime, uint32 dungeonId)
 
void UpdateQueueTimers (uint8 queueId, time_t currTime)
 
time_t GetJoinTime (ObjectGuid guid) const
 
uint8 FindGroups ()
 
std::string DumpQueueInfo () const
 
std::string DumpCompatibleInfo (bool full=false) const
 

Private Member Functions

void SetQueueUpdateData (std::string const &strGuids, LfgRolesMap const &proposalRoles)
 
void AddToNewQueue (ObjectGuid guid)
 
void AddToCurrentQueue (ObjectGuid guid)
 
void AddToFrontCurrentQueue (ObjectGuid guid)
 
void RemoveFromNewQueue (ObjectGuid guid)
 
void RemoveFromCurrentQueue (ObjectGuid guid)
 
void SetCompatibles (std::string const &key, LfgCompatibility compatibles)
 
LfgCompatibility GetCompatibles (std::string const &key)
 
void RemoveFromCompatibles (ObjectGuid guid)
 
void SetCompatibilityData (std::string const &key, LfgCompatibilityData const &compatibles)
 
LfgCompatibilityDataGetCompatibilityData (std::string const &key)
 
void FindBestCompatibleInQueue (LfgQueueDataContainer::iterator itrQueue)
 
void UpdateBestCompatibleInQueue (LfgQueueDataContainer::iterator itrQueue, std::string const &key, LfgRolesMap const &roles)
 
LfgCompatibility FindNewGroups (GuidList &check, GuidList &all)
 
LfgCompatibility CheckCompatibility (GuidList check)
 

Private Attributes

LfgQueueDataContainer QueueDataStore
 Queued groups. More...
 
LfgCompatibleContainer CompatibleMapStore
 Compatible dungeons. More...
 
LfgWaitTimesContainer waitTimesAvgStore
 Average wait time to find a group queuing as multiple roles. More...
 
LfgWaitTimesContainer waitTimesTankStore
 Average wait time to find a group queuing as tank. More...
 
LfgWaitTimesContainer waitTimesHealerStore
 Average wait time to find a group queuing as healer. More...
 
LfgWaitTimesContainer waitTimesDpsStore
 Average wait time to find a group queuing as dps. More...
 
GuidList currentQueueStore
 Ordered list. Used to find groups. More...
 
GuidList newToQueueStore
 New groups to add to queue. More...
 

Detailed Description

Stores all data related to queue

Definition at line 85 of file LFGQueue.h.

Member Function Documentation

◆ AddQueueData()

void lfg::LFGQueue::AddQueueData ( ObjectGuid  guid,
time_t  joinTime,
LfgDungeonSet const &  dungeons,
LfgRolesMap const &  rolesMap 
)

Definition at line 188 of file LFGQueue.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ AddToCurrentQueue()

void lfg::LFGQueue::AddToCurrentQueue ( ObjectGuid  guid)
private

Definition at line 173 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ AddToFrontCurrentQueue()

void lfg::LFGQueue::AddToFrontCurrentQueue ( ObjectGuid  guid)
private

Definition at line 178 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ AddToNewQueue()

void lfg::LFGQueue::AddToNewQueue ( ObjectGuid  guid)
private

Definition at line 163 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ AddToQueue()

void lfg::LFGQueue::AddToQueue ( ObjectGuid  guid,
bool  reAdd = false 
)

Definition at line 123 of file LFGQueue.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ CheckCompatibility()

LfgCompatibility lfg::LFGQueue::CheckCompatibility ( GuidList  check)
private

Check compatibilities between groups. If group is Matched proposal will be created

Parameters
[in]checkList of guids to check compatibilities
Returns
LfgCompatibility type of compatibility

Definition at line 358 of file LFGQueue.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ DumpCompatibleInfo()

std::string lfg::LFGQueue::DumpCompatibleInfo ( bool  full = false) const

Definition at line 668 of file LFGQueue.cpp.

+ Here is the call graph for this function:

◆ DumpQueueInfo()

std::string lfg::LFGQueue::DumpQueueInfo ( ) const

Definition at line 642 of file LFGQueue.cpp.

+ Here is the call graph for this function:

◆ FindBestCompatibleInQueue()

void lfg::LFGQueue::FindBestCompatibleInQueue ( LfgQueueDataContainer::iterator  itrQueue)
private

Definition at line 695 of file LFGQueue.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ FindGroups()

uint8 lfg::LFGQueue::FindGroups ( )

Definition at line 288 of file LFGQueue.cpp.

+ Here is the call graph for this function:

◆ FindNewGroups()

LfgCompatibility lfg::LFGQueue::FindNewGroups ( GuidList check,
GuidList all 
)
private

Checks que main queue to try to form a Lfg group. Returns first match found (if any)

Parameters
[in]checkList of guids trying to match with other groups
[in]allList of all other guids in main queue to match against
Returns
LfgCompatibility type of compatibility between groups

Definition at line 320 of file LFGQueue.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetCompatibilityData()

LfgCompatibilityData * lfg::LFGQueue::GetCompatibilityData ( std::string const &  key)
private

Definition at line 279 of file LFGQueue.cpp.

◆ GetCompatibles()

LfgCompatibility lfg::LFGQueue::GetCompatibles ( std::string const &  key)
private

Get the compatibility of a group of guids

Parameters
[in]keyString concatenation of guids (| used as separator)
Returns
LfgCompatibility type of compatibility

Definition at line 270 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ GetDetailedMatchRoles()

std::string lfg::LFGQueue::GetDetailedMatchRoles ( GuidList const &  check) const

Definition at line 86 of file LFGQueue.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetJoinTime()

time_t lfg::LFGQueue::GetJoinTime ( ObjectGuid  guid) const

Definition at line 633 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ RemoveFromCompatibles()

void lfg::LFGQueue::RemoveFromCompatibles ( ObjectGuid  guid)
private

Remove from cached compatible dungeons any entry that contains the given guid

Parameters
[in]guidGuid to remove from compatible cache

Definition at line 234 of file LFGQueue.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ RemoveFromCurrentQueue()

void lfg::LFGQueue::RemoveFromCurrentQueue ( ObjectGuid  guid)
private

Definition at line 183 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ RemoveFromNewQueue()

void lfg::LFGQueue::RemoveFromNewQueue ( ObjectGuid  guid)
private

Definition at line 168 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ RemoveFromQueue()

void lfg::LFGQueue::RemoveFromQueue ( ObjectGuid  guid)

Definition at line 138 of file LFGQueue.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ RemoveQueueData()

void lfg::LFGQueue::RemoveQueueData ( ObjectGuid  guid)

Definition at line 194 of file LFGQueue.cpp.

◆ SetCompatibilityData()

void lfg::LFGQueue::SetCompatibilityData ( std::string const &  key,
LfgCompatibilityData const &  compatibles 
)
private

Definition at line 259 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ SetCompatibles()

void lfg::LFGQueue::SetCompatibles ( std::string const &  key,
LfgCompatibility  compatibles 
)
private

Stores the compatibility of a list of guids

Parameters
[in]keyString concatenation of guids (| used as separator)
[in]compatiblestype of compatibility

Definition at line 253 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ SetQueueUpdateData()

void lfg::LFGQueue::SetQueueUpdateData ( std::string const &  strGuids,
LfgRolesMap const &  proposalRoles 
)
private

◆ UpdateBestCompatibleInQueue()

void lfg::LFGQueue::UpdateBestCompatibleInQueue ( LfgQueueDataContainer::iterator  itrQueue,
std::string const &  key,
LfgRolesMap const &  roles 
)
private

Definition at line 708 of file LFGQueue.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ UpdateQueueTimers()

void lfg::LFGQueue::UpdateQueueTimers ( uint8  queueId,
time_t  currTime 
)

Definition at line 583 of file LFGQueue.cpp.

+ Here is the call graph for this function:

◆ UpdateWaitTimeAvg()

void lfg::LFGQueue::UpdateWaitTimeAvg ( int32  waitTime,
uint32  dungeonId 
)

Definition at line 201 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ UpdateWaitTimeDps()

void lfg::LFGQueue::UpdateWaitTimeDps ( int32  waitTime,
uint32  dungeonId 
)

Definition at line 222 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ UpdateWaitTimeHealer()

void lfg::LFGQueue::UpdateWaitTimeHealer ( int32  waitTime,
uint32  dungeonId 
)

Definition at line 215 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

◆ UpdateWaitTimeTank()

void lfg::LFGQueue::UpdateWaitTimeTank ( int32  waitTime,
uint32  dungeonId 
)

Definition at line 208 of file LFGQueue.cpp.

+ Here is the caller graph for this function:

Member Data Documentation

◆ CompatibleMapStore

LfgCompatibleContainer lfg::LFGQueue::CompatibleMapStore
private

Compatible dungeons.

Definition at line 136 of file LFGQueue.h.

◆ currentQueueStore

GuidList lfg::LFGQueue::currentQueueStore
private

Ordered list. Used to find groups.

Definition at line 142 of file LFGQueue.h.

◆ newToQueueStore

GuidList lfg::LFGQueue::newToQueueStore
private

New groups to add to queue.

Definition at line 143 of file LFGQueue.h.

◆ QueueDataStore

LfgQueueDataContainer lfg::LFGQueue::QueueDataStore
private

Queued groups.

Definition at line 135 of file LFGQueue.h.

◆ waitTimesAvgStore

LfgWaitTimesContainer lfg::LFGQueue::waitTimesAvgStore
private

Average wait time to find a group queuing as multiple roles.

Definition at line 138 of file LFGQueue.h.

◆ waitTimesDpsStore

LfgWaitTimesContainer lfg::LFGQueue::waitTimesDpsStore
private

Average wait time to find a group queuing as dps.

Definition at line 141 of file LFGQueue.h.

◆ waitTimesHealerStore

LfgWaitTimesContainer lfg::LFGQueue::waitTimesHealerStore
private

Average wait time to find a group queuing as healer.

Definition at line 140 of file LFGQueue.h.

◆ waitTimesTankStore

LfgWaitTimesContainer lfg::LFGQueue::waitTimesTankStore
private

Average wait time to find a group queuing as tank.

Definition at line 139 of file LFGQueue.h.


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