ManaPlus
Public Member Functions | Data Fields
BeingsListModel Class Reference

#include <beingslistmodel.h>

Inheritance diagram for BeingsListModel:
AvatarListModel ListModel

Public Member Functions

 BeingsListModel ()
 
 ~BeingsListModel ()
 
std::vector< Avatar * > * getMembers ()
 
AvatargetAvatarAt (int index)
 
int getNumberOfElements ()
 
- Public Member Functions inherited from AvatarListModel
 AvatarListModel ()
 
std::string getElementAt (int i)
 
- Public Member Functions inherited from ListModel
 ListModel ()
 
virtual ~ListModel ()
 

Data Fields

std::vector< Avatar * > mMembers
 

Detailed Description

Definition at line 32 of file beingslistmodel.h.

Constructor & Destructor Documentation

◆ BeingsListModel()

BeingsListModel::BeingsListModel ( )
inline

Definition at line 35 of file beingslistmodel.h.

35  :
37  mMembers()
38  {
39  }
std::vector< Avatar * > mMembers

◆ ~BeingsListModel()

BeingsListModel::~BeingsListModel ( )
inline

Definition at line 43 of file beingslistmodel.h.

44  {
46  mMembers.clear();
47  }
void delete_all(Container &c)
Definition: dtor.h:56

References delete_all(), and mMembers.

Member Function Documentation

◆ getAvatarAt()

Avatar* BeingsListModel::getAvatarAt ( int  index)
inlinevirtual

Implements AvatarListModel.

Definition at line 54 of file beingslistmodel.h.

55  {
56  return mMembers[index];
57  }

References mMembers.

◆ getMembers()

std::vector<Avatar*>* BeingsListModel::getMembers ( )
inline

◆ getNumberOfElements()

int BeingsListModel::getNumberOfElements ( )
inlinevirtual

Gets the number of elements in the list.

Returns
The number of elements in the list

Implements ListModel.

Definition at line 59 of file beingslistmodel.h.

60  {
61  return CAST_S32(mMembers.size());
62  }
#define CAST_S32
Definition: cast.h:30

References CAST_S32, and mMembers.

Field Documentation

◆ mMembers

std::vector<Avatar*> BeingsListModel::mMembers

Definition at line 64 of file beingslistmodel.h.

Referenced by getAvatarAt(), getMembers(), getNumberOfElements(), and ~BeingsListModel().


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