Code_TYMPAN  4.4.0
Industrial site acoustic simulation
Static Public Member Functions | Private Types | Static Private Member Functions | Static Private Attributes | List of all members
OLocalizator Class Reference

#include <OLocalizator.h>

Collaboration diagram for OLocalizator:
Collaboration graph
[legend]

Static Public Member Functions

static bool setRessourceFile (const QString &filename)
 
static void setRessourcePath (const QString &path)
 
static bool isRessourceFile ()
 
static QString getString (const QString &classname, const QString &stringId)
 
static QString getPicture (const QString &classname, const QString &pictureId)
 

Private Types

typedef QMap< QString, QString > OptimMap
 

Static Private Member Functions

static bool selectClassDirectory (const QString &classname)
 
static bool findIdAndSetValue (const QString &directory, const QString &stringId, QString &returnString)
 

Static Private Attributes

static bool _isRessourceFile = false
 
static OptimMap _stringMap
 
static QString _ressourcePath
 
static OXMLTreeManager _treeManager
 

Detailed Description

A Class to handle application an plugin ressources. It allows to store strings and reference sounds and picture outside the application. It can be used to localize the plugins or the application.

Definition at line 38 of file OLocalizator.h.

Member Typedef Documentation

◆ OptimMap

typedef QMap<QString, QString> OLocalizator::OptimMap
private

Definition at line 81 of file OLocalizator.h.

Member Function Documentation

◆ findIdAndSetValue()

bool OLocalizator::findIdAndSetValue ( const QString &  directory,
const QString &  stringId,
QString &  returnString 
)
staticprivate

Definition at line 127 of file OLocalizator.cpp.

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

◆ getPicture()

QString OLocalizator::getPicture ( const QString &  classname,
const QString &  pictureId 
)
static

Returns a picture full path name, identified by its id and used by the class Classname.

Parameters
classnameName of the class using this picture.
pictureIdIdentifier of this picture

Definition at line 64 of file OLocalizator.cpp.

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

◆ getString()

QString OLocalizator::getString ( const QString &  classname,
const QString &  stringId 
)
static

Returns a string identified by its id and used by the class Classname.

Parameters
classnameName of the class using this string.
stringIdIdentifier of this string.

Definition at line 38 of file OLocalizator.cpp.

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

◆ isRessourceFile()

static bool OLocalizator::isRessourceFile ( )
inlinestatic

Return true if ressource file is loaded, false otherwise.

Definition at line 57 of file OLocalizator.h.

Here is the caller graph for this function:

◆ selectClassDirectory()

bool OLocalizator::selectClassDirectory ( const QString &  classname)
staticprivate

Definition at line 98 of file OLocalizator.cpp.

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

◆ setRessourceFile()

bool OLocalizator::setRessourceFile ( const QString &  filename)
static

Load a file containing the ressources for a particular language.

Parameters
filenameXML filename (Mcs ressource format).

Definition at line 31 of file OLocalizator.cpp.

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

◆ setRessourcePath()

static void OLocalizator::setRessourcePath ( const QString &  path)
inlinestatic

Sets the absolute directory path of the sounds and pictures.

Parameters
pathFile path of the picture and sounds to be used in the application.

Definition at line 50 of file OLocalizator.h.

Here is the caller graph for this function:

Member Data Documentation

◆ _isRessourceFile

bool OLocalizator::_isRessourceFile = false
staticprivate

Definition at line 79 of file OLocalizator.h.

◆ _ressourcePath

QString OLocalizator::_ressourcePath
staticprivate

Definition at line 83 of file OLocalizator.h.

◆ _stringMap

OLocalizator::OptimMap OLocalizator::_stringMap
staticprivate

Definition at line 82 of file OLocalizator.h.

◆ _treeManager

OXMLTreeManager OLocalizator::_treeManager
staticprivate

Definition at line 84 of file OLocalizator.h.


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