Pol  Revision:cb584c9
Pol::Core::Party Class Reference

#include <party.h>

+ Inheritance diagram for Pol::Core::Party:

Public Member Functions

 Party (Clib::ConfigElem &elem)
 Party (u32 serial)
bool add_candidate (u32 serial)
bool add_member (u32 serial)
void add_offline_mem (u32 serial)
bool can_add () const
void cleanup ()
void disband ()
size_t estimateSize () const
u32 get_member_at (unsigned short pos) const
bool is_candidate (u32 serial) const
bool is_leader (u32 serial) const
bool is_member (u32 serial) const
u32 leader () const
void on_mana_changed (Mobile::Character *chr) const
void on_stam_changed (Mobile::Character *chr) const
void printOn (Clib::StreamWriter &sw) const
bool register_with_members ()
bool remove_candidate (u32 serial)
bool remove_member (u32 serial)
bool remove_offline_mem (u32 serial)
void send_member_list (Mobile::Character *to_chr)
void send_member_msg_private (Mobile::Character *chr, Mobile::Character *tochr, u16 *wtext, size_t wtextlen) const
void send_member_msg_public (Mobile::Character *chr, u16 *wtext, size_t wtextlen) const
void send_msg_to_all (unsigned int clilocnr, const char *affix=0, Mobile::Character *exeptchr=nullptr) const
void send_remove_member (Mobile::Character *chr, bool *disband)
void send_stat_to (Mobile::Character *chr, Mobile::Character *bob) const
void send_stats_on_add (Mobile::Character *newmember) const
void set_leader (u32 serial)
bool test_size () const
- Public Member Functions inherited from ref_counted
unsigned int add_ref ()
unsigned int count () const
unsigned int release ()

Private Attributes

std::vector< u32_candidates_serials
u32 _leaderserial
std::vector< u32_member_serials
std::vector< u32_offlinemember_serials
PropertyList _proplist


class Module::EPartyRefObjImp

Additional Inherited Members

- Protected Member Functions inherited from ref_counted
 ref_counted ()
 ~ref_counted ()=default
- Protected Attributes inherited from ref_counted
std::atomic< unsigned int > _count

Detailed Description

Definition at line 56 of file party.h.

Constructor & Destructor Documentation

Pol::Core::Party::Party ( u32  serial)

Definition at line 65 of file party.cpp.

References _member_serials.

Member Function Documentation

void Pol::Core::Party::add_offline_mem ( u32  serial)

Definition at line 347 of file party.cpp.

References _offlinemember_serials.

Referenced by Pol::Core::on_loggoff_party().

void Pol::Core::Party::cleanup ( )

Definition at line 269 of file party.cpp.

References _candidates_serials, _member_serials, and _offlinemember_serials.

size_t Pol::Core::Party::estimateSize ( ) const
u32 Pol::Core::Party::get_member_at ( unsigned short  pos) const

Definition at line 322 of file party.cpp.

References _member_serials.

Referenced by Pol::Core::handle_party_msg(), and Pol::Core::on_loggoff_party().

bool Pol::Core::Party::is_candidate ( u32  serial) const

Definition at line 287 of file party.cpp.

References _candidates_serials.

Referenced by Pol::Core::add_candidate().

bool Pol::Core::Party::is_leader ( u32  serial) const
void Pol::Core::Party::printOn ( Clib::StreamWriter sw) const
bool Pol::Core::Party::register_with_members ( )
bool Pol::Core::Party::remove_candidate ( u32  serial)
bool Pol::Core::Party::remove_member ( u32  serial)
bool Pol::Core::Party::remove_offline_mem ( u32  serial)

Definition at line 376 of file party.cpp.

References _offlinemember_serials.

Referenced by Pol::Core::on_loggon_party().

void Pol::Core::Party::set_leader ( u32  serial)

Definition at line 388 of file party.cpp.

References _leaderserial, and _member_serials.

Referenced by Pol::Core::on_loggoff_party().

bool Pol::Core::Party::test_size ( ) const

Friends And Related Function Documentation

friend class Module::EPartyRefObjImp

Definition at line 92 of file party.h.

Member Data Documentation

std::vector<u32> Pol::Core::Party::_candidates_serials
u32 Pol::Core::Party::_leaderserial
std::vector<u32> Pol::Core::Party::_offlinemember_serials

Definition at line 97 of file party.h.

Referenced by add_offline_mem(), cleanup(), disband(), estimateSize(), and remove_offline_mem().

PropertyList Pol::Core::Party::_proplist

Definition at line 99 of file party.h.

Referenced by estimateSize(), Party(), and printOn().

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