HoverRace
2.0
|
The collection of player profiles on this system. More...
#include <ProfileGallery.h>
Public Types | |
using | const_iterator = profiles_t::const_iterator |
using | iterator = profiles_t::iterator |
using | value_type = profiles_t::value_type |
Public Member Functions | |
ProfileGallery (std::shared_ptr< AvatarGallery > avatarGallery, const Util::OS::path_t &path={}) | |
Constructor. More... | |
const_iterator | begin () const |
iterator | begin () |
const_iterator | end () const |
iterator | end () |
std::shared_ptr< Profile > | FindName (const std::string &name) const |
Find a profile by name. More... | |
std::shared_ptr< Profile > | FindUid (const std::string &uid) const |
Find a profile by UID. More... | |
std::shared_ptr< Profile > | FindUid (const boost::uuids::uuid &uid) const |
Find a profile by UID. More... | |
bool | IsEmpty () const |
void | Reload () |
Reload all profiles. More... | |
Private Types | |
using | profiles_t = std::vector< std::shared_ptr< Profile >> |
Private Attributes | |
std::shared_ptr< AvatarGallery > | avatarGallery |
Util::OS::path_t | path |
profiles_t | profiles |
The collection of player profiles on this system.
using HoverRace::Player::ProfileGallery::const_iterator = profiles_t::const_iterator |
using HoverRace::Player::ProfileGallery::iterator = profiles_t::iterator |
|
private |
using HoverRace::Player::ProfileGallery::value_type = profiles_t::value_type |
HoverRace::Player::ProfileGallery::ProfileGallery | ( | std::shared_ptr< AvatarGallery > | avatarGallery, |
const Util::OS::path_t & | path = {} |
||
) |
Constructor.
avatarGallery | The avatar gallery. |
path | The base profile directory (may be empty to use default). |
ProfileExn | The full list of profiles could not be loaded. |
|
inline |
|
inline |
|
inline |
|
inline |
std::shared_ptr< Profile > HoverRace::Player::ProfileGallery::FindName | ( | const std::string & | name | ) | const |
Find a profile by name.
name | The name. |
nullptr
if the profile does not exist. std::shared_ptr< Profile > HoverRace::Player::ProfileGallery::FindUid | ( | const std::string & | uid | ) | const |
Find a profile by UID.
uid | The UID as a string (may be empty). |
nullptr
if the profile does not exist. std::shared_ptr< Profile > HoverRace::Player::ProfileGallery::FindUid | ( | const boost::uuids::uuid & | uid | ) | const |
Find a profile by UID.
uid | The UID. |
nullptr
if the profile does not exist.
|
inline |
void HoverRace::Player::ProfileGallery::Reload | ( | ) |
Reload all profiles.
ProfileExn | The full list of profiles could not be loaded. |
|
private |
|
private |
|
private |