TrinityCore
|
#include <GuildFinderMgr.h>
Public Member Functions | |
void | LoadFromDB () |
void | SetGuildSettings (ObjectGuid const &guildGuid, LFGuildSettings const &settings) |
Stores guild settings and begins an asynchronous database insert. More... | |
LFGuildSettings const & | GetGuildSettings (ObjectGuid const &guildGuid) |
Returns settings for a guild. More... | |
void | AddMembershipRequest (ObjectGuid const &guildGuid, MembershipRequest const &request) |
Files a membership request to a guild. More... | |
void | RemoveAllMembershipRequestsFromPlayer (ObjectGuid const &playerId) |
Removes all membership request from a player. More... | |
void | RemoveMembershipRequest (ObjectGuid const &playerId, ObjectGuid const &guildId) |
Removes a membership request to a guild. More... | |
void | DeleteGuild (ObjectGuid const &guildId) |
Wipes everything related to a guild. Used when that guild is disbanded. More... | |
std::unordered_map< ObjectGuid, MembershipRequest > const * | GetAllMembershipRequestsForGuild (ObjectGuid const &guildGuid) |
Returns a set of membership requests for a guild. More... | |
std::vector< MembershipRequest const * > | GetAllMembershipRequestsForPlayer (ObjectGuid const &playerGuid) |
Returns a list of membership requests for a player. More... | |
std::vector< LFGuildSettings const * > | GetGuildsMatchingSetting (LFGuildPlayer &settings, TeamId faction) |
Returns a store of guilds matching the settings provided, using bitmask operators. More... | |
bool | HasRequest (ObjectGuid const &playerId, ObjectGuid const &guildId) |
Provided a player guid and a guild guid, determines if a pending request is filed with these keys. More... | |
uint8 | CountRequestsFromPlayer (ObjectGuid const &playerId) |
Counts the amount of pending membership requests, given the player's db guid. More... | |
Static Public Member Functions | |
static void | SendApplicantListUpdate (Guild *guild) |
static void | SendMembershipRequestListUpdate (Player *player) |
static GuildFinderMgr * | instance () |
Private Member Functions | |
GuildFinderMgr () | |
~GuildFinderMgr () | |
void | LoadGuildSettings () |
void | LoadMembershipRequests () |
Private Attributes | |
LFGuildStore | _guildSettings |
std::unordered_map< ObjectGuid, std::unordered_map< ObjectGuid, MembershipRequest > > | _membershipRequestsByGuild |
std::unordered_map< ObjectGuid, std::unordered_map< ObjectGuid, MembershipRequest > > | _membershipRequestsByPlayer |
void GuildFinderMgr::AddMembershipRequest | ( | ObjectGuid const & | guildGuid, |
MembershipRequest const & | request | ||
) |
Files a membership request to a guild.
guildGuid | The guild's database GUID. |
MembershipRequest | An object storing all data related to the request. |
uint8 GuildFinderMgr::CountRequestsFromPlayer | ( | ObjectGuid const & | playerId | ) |
Counts the amount of pending membership requests, given the player's db guid.
void GuildFinderMgr::DeleteGuild | ( | ObjectGuid const & | guildId | ) |
Wipes everything related to a guild. Used when that guild is disbanded.
|
inline |
Returns a set of membership requests for a guild.
guildGuid | The guild's database guid. |
std::vector< MembershipRequest const * > GuildFinderMgr::GetAllMembershipRequestsForPlayer | ( | ObjectGuid const & | playerGuid | ) |
Returns a list of membership requests for a player.
playerGuid | The player's database guid. |
|
inline |
Returns settings for a guild.
guildGuid | The guild's database guid. |
std::vector< LFGuildSettings const * > GuildFinderMgr::GetGuildsMatchingSetting | ( | LFGuildPlayer & | settings, |
TeamId | faction | ||
) |
Returns a store of guilds matching the settings provided, using bitmask operators.
settings | The player's finder settings |
teamId | The player's faction (TEAM_ALLIANCE or TEAM_HORDE) |
bool GuildFinderMgr::HasRequest | ( | ObjectGuid const & | playerId, |
ObjectGuid const & | guildId | ||
) |
Provided a player guid and a guild guid, determines if a pending request is filed with these keys.
|
static |
void GuildFinderMgr::LoadFromDB | ( | ) |
|
private |
|
private |
void GuildFinderMgr::RemoveAllMembershipRequestsFromPlayer | ( | ObjectGuid const & | playerId | ) |
Removes all membership request from a player.
playerId | The player's database guid whose application shall be deleted. |
void GuildFinderMgr::RemoveMembershipRequest | ( | ObjectGuid const & | playerId, |
ObjectGuid const & | guildId | ||
) |
Removes a membership request to a guild.
playerId | The player's database guid whose application shall be deleted. |
guildId | The guild's database guid |
|
static |
|
static |
void GuildFinderMgr::SetGuildSettings | ( | ObjectGuid const & | guildGuid, |
LFGuildSettings const & | settings | ||
) |
Stores guild settings and begins an asynchronous database insert.
guildGuid | The guild's database guid. |
LFGuildSettings | The guild's settings storage. |
|
private |
|
private |
|
private |