TrinityCore
Loading...
Searching...
No Matches
PlayerSocial Class Reference

#include <SocialMgr.h>

Public Member Functions

 PlayerSocial ()
 
 PlayerSocial (PlayerSocial const &)
 
 PlayerSocial (PlayerSocial &&) noexcept
 
PlayerSocial & operator= (PlayerSocial const &)
 
PlayerSocial & operator= (PlayerSocial &&) noexcept
 
 ~PlayerSocial ()
 
bool AddToSocialList (ObjectGuid const &guid, ObjectGuid const &accountGuid, SocialFlag flag)
 
void RemoveFromSocialList (ObjectGuid const &guid, SocialFlag flag)
 
void SetFriendNote (ObjectGuid const &guid, std::string const &note)
 
void SendSocialList (Player *player, uint32 flags)
 
bool HasFriend (ObjectGuid const &friendGuid)
 
bool HasIgnore (ObjectGuid const &ignoreGuid, ObjectGuid const &ignoreAccountGuid)
 
ObjectGuid const & GetPlayerGUID () const
 
void SetPlayerGUID (ObjectGuid const &guid)
 
uint32 GetNumberOfSocialsWithFlag (SocialFlag flag)
 

Private Types

typedef std::map< ObjectGuid, FriendInfo > PlayerSocialMap
 

Private Member Functions

bool _HasContact (ObjectGuid const &guid, SocialFlag flags)
 

Private Attributes

PlayerSocialMap _playerSocialMap
 
GuidUnorderedSet _ignoredAccounts
 
ObjectGuid _playerGUID
 

Friends

class SocialMgr
 

Detailed Description

Definition at line 103 of file SocialMgr.h.

Member Typedef Documentation

◆ PlayerSocialMap

Definition at line 135 of file SocialMgr.h.

Constructor & Destructor Documentation

◆ PlayerSocial() [1/3]

PlayerSocial::PlayerSocial ( )
default

◆ PlayerSocial() [2/3]

PlayerSocial::PlayerSocial ( PlayerSocial const &  )
default

◆ PlayerSocial() [3/3]

PlayerSocial::PlayerSocial ( PlayerSocial &&  )
defaultnoexcept

◆ ~PlayerSocial()

PlayerSocial::~PlayerSocial ( )
default

Member Function Documentation

◆ _HasContact()

bool PlayerSocial::_HasContact ( ObjectGuid const &  guid,
SocialFlag  flags 
)
private

Definition at line 192 of file SocialMgr.cpp.

References _playerSocialMap, and flags.

Referenced by HasFriend(), and HasIgnore().

◆ AddToSocialList()

◆ GetNumberOfSocialsWithFlag()

uint32 PlayerSocial::GetNumberOfSocialsWithFlag ( SocialFlag  flag)

Definition at line 34 of file SocialMgr.cpp.

Referenced by AddToSocialList().

◆ GetPlayerGUID()

ObjectGuid const & PlayerSocial::GetPlayerGUID ( ) const
inline

Definition at line 127 of file SocialMgr.h.

Referenced by AddToSocialList(), RemoveFromSocialList(), and SetFriendNote().

◆ HasFriend()

bool PlayerSocial::HasFriend ( ObjectGuid const &  friendGuid)

◆ HasIgnore()

◆ operator=() [1/2]

PlayerSocial & PlayerSocial::operator= ( PlayerSocial &&  )
defaultnoexcept

◆ operator=() [2/2]

PlayerSocial & PlayerSocial::operator= ( PlayerSocial const &  )
default

◆ RemoveFromSocialList()

◆ SendSocialList()

◆ SetFriendNote()

◆ SetPlayerGUID()

void PlayerSocial::SetPlayerGUID ( ObjectGuid const &  guid)
inline

Definition at line 128 of file SocialMgr.h.

Referenced by SocialMgr::LoadFromDB().

Friends And Related Symbol Documentation

◆ SocialMgr

friend class SocialMgr
friend

Definition at line 105 of file SocialMgr.h.

Member Data Documentation

◆ _ignoredAccounts

GuidUnorderedSet PlayerSocial::_ignoredAccounts
private

◆ _playerGUID

ObjectGuid PlayerSocial::_playerGUID
private

Definition at line 139 of file SocialMgr.h.

◆ _playerSocialMap


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