Crossfire Server, Trunk  R22047
ResourcesManager Class Reference

#include <ResourcesManager.h>

+ Inheritance diagram for ResourcesManager:
+ Collaboration diagram for ResourcesManager:

Public Member Functions

virtual void assetDefined (const archt *arch, const std::string &filename)
 
void load ()
 
const QHash< QString, QList< const archt * > > & origins () const
 
const recipestructrecipe (int ingredients, const QString &name) const
 
int recipeMaxIngredients () const
 
QStringList recipes (int count) const
 
 ResourcesManager ()
 
virtual ~ResourcesManager ()
 

Static Public Member Functions

static void archetypeUse (const archt *item, CREMapInformationManager *store, AssetUseCallback callback)
 

Protected Attributes

QHash< QString, QList< const archt * > > myOrigins
 
QList< QHash< QString, recipestruct * > > myRecipes
 

Detailed Description

Definition at line 24 of file ResourcesManager.h.

Constructor & Destructor Documentation

◆ ResourcesManager()

ResourcesManager::ResourcesManager ( )

Definition at line 20 of file ResourcesManager.cpp.

◆ ~ResourcesManager()

ResourcesManager::~ResourcesManager ( )
virtual

Definition at line 24 of file ResourcesManager.cpp.

Member Function Documentation

◆ archetypeUse()

◆ assetDefined()

void ResourcesManager::assetDefined ( const archt *  arch,
const std::string &  filename 
)
virtual

Implements AssetsTracker< archt >.

Definition at line 79 of file ResourcesManager.cpp.

References myOrigins.

◆ load()

void ResourcesManager::load ( )

Definition at line 28 of file ResourcesManager.cpp.

References add_server_collect_hooks(), Settings::archetypes_tracker, get_formulalist(), init_globals(), init_library(), recipeliststruct::items, myRecipes, recipestruct::next, recipes(), and settings.

Referenced by CREMainWindow::CREMainWindow().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ origins()

const QHash<QString, QList<const archt*> >& ResourcesManager::origins ( ) const
inline

Definition at line 38 of file ResourcesManager.h.

References archetypeUse(), and myOrigins.

Referenced by EditMonstersDialog::onSaveChanges().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ recipe()

const recipe * ResourcesManager::recipe ( int  ingredients,
const QString &  name 
) const

Definition at line 70 of file ResourcesManager.cpp.

References myRecipes.

Referenced by CREResourcesWindow::fillFormulae().

+ Here is the caller graph for this function:

◆ recipeMaxIngredients()

int ResourcesManager::recipeMaxIngredients ( ) const

Definition at line 55 of file ResourcesManager.cpp.

References myRecipes.

Referenced by CREResourcesWindow::fillFormulae().

+ Here is the caller graph for this function:

◆ recipes()

QStringList ResourcesManager::recipes ( int  count) const

Definition at line 60 of file ResourcesManager.cpp.

References myRecipes.

Referenced by CREResourcesWindow::fillFormulae(), and load().

+ Here is the caller graph for this function:

Field Documentation

◆ myOrigins

QHash<QString, QList<const archt*> > ResourcesManager::myOrigins
protected

Definition at line 43 of file ResourcesManager.h.

Referenced by assetDefined(), and origins().

◆ myRecipes

QList<QHash<QString, recipestruct*> > ResourcesManager::myRecipes
protected

Definition at line 44 of file ResourcesManager.h.

Referenced by load(), recipe(), recipeMaxIngredients(), and recipes().


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