OpenMW
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Public Types | Public Member Functions | Private Member Functions | Private Attributes | List of all members
MWState::Character Class Reference

#include <character.hpp>

Collaboration diagram for MWState::Character:

Public Types

typedef std::vector< Slot >
::const_reverse_iterator 
SlotIterator
 

Public Member Functions

 Character (const boost::filesystem::path &saves, const std::string &game)
 
void cleanup ()
 Delete the directory we used, if it is empty. More...
 
const SlotcreateSlot (const ESM::SavedGame &profile)
 
void deleteSlot (const Slot *slot)
 
const SlotupdateSlot (const Slot *slot, const ESM::SavedGame &profile)
 
SlotIterator begin () const
 Any call to createSlot and updateSlot can invalidate the returned iterator. More...
 
SlotIterator end () const
 
const boost::filesystem::path & getPath () const
 
ESM::SavedGame getSignature () const
 

Private Member Functions

void addSlot (const boost::filesystem::path &path, const std::string &game)
 
void addSlot (const ESM::SavedGame &profile)
 

Private Attributes

boost::filesystem::path mPath
 
std::vector< SlotmSlots
 

Member Typedef Documentation

typedef std::vector<Slot>::const_reverse_iterator MWState::Character::SlotIterator

Constructor & Destructor Documentation

MWState::Character::Character ( const boost::filesystem::path &  saves,
const std::string &  game 
)

Here is the call graph for this function:

Member Function Documentation

void MWState::Character::addSlot ( const boost::filesystem::path &  path,
const std::string &  game 
)
private

Here is the call graph for this function:

Here is the caller graph for this function:

void MWState::Character::addSlot ( const ESM::SavedGame profile)
private

Here is the call graph for this function:

MWState::Character::SlotIterator MWState::Character::begin ( ) const

Any call to createSlot and updateSlot can invalidate the returned iterator.

Note
Slot must belong to this character.
Attention
The slot pointer will be invalidated by this call.

Here is the caller graph for this function:

void MWState::Character::cleanup ( )

Delete the directory we used, if it is empty.

Here is the caller graph for this function:

const MWState::Slot * MWState::Character::createSlot ( const ESM::SavedGame profile)

Create new slot.

Attention
The ownership of the slot is not transferred.

Here is the caller graph for this function:

void MWState::Character::deleteSlot ( const Slot slot)
Note
Slot must belong to this character.
Attention
The slot pointer will be invalidated by this call.

Here is the caller graph for this function:

MWState::Character::SlotIterator MWState::Character::end ( ) const

Here is the caller graph for this function:

const boost::filesystem::path & MWState::Character::getPath ( ) const

Here is the caller graph for this function:

ESM::SavedGame MWState::Character::getSignature ( ) const

Return signature information for this character.

Attention
This function must not be called if there are no slots.
const MWState::Slot * MWState::Character::updateSlot ( const Slot slot,
const ESM::SavedGame profile 
)

Here is the caller graph for this function:

Member Data Documentation

boost::filesystem::path MWState::Character::mPath
private
std::vector<Slot> MWState::Character::mSlots
private

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