Torque2D Reference
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
LangFile Class Reference

Class for working with language files. More...

#include <lang.h>

Public Member Functions

 LangFile (const UTF8 *langName=NULL)
 
virtual ~LangFile ()
 
bool load (const UTF8 *filename)
 
bool save (const UTF8 *filename)
 
bool load (Stream *s)
 
bool save (Stream *s)
 
const UTF8 * getString (U32 id)
 
U32 addString (const UTF8 *str)
 
void setString (U32 id, const UTF8 *str)
 
void setLangName (const UTF8 *newName)
 
const UTF8 * getLangName (void)
 
const UTF8 * getLangFile (void)
 
void setLangFile (const UTF8 *langFile)
 
bool activateLanguage (void)
 
void deactivateLanguage (void)
 
bool isLoaded (void)
 
S32 getNumStrings (void)
 

Protected Member Functions

void freeTable ()
 

Protected Attributes

Vector< UTF8 * > mStringTable
 
UTF8 * mLangName
 
UTF8 * mLangFile
 

Detailed Description

Class for working with language files.

Constructor & Destructor Documentation

LangFile ( const UTF8 *  langName = NULL)
~LangFile ( )
virtual

Member Function Documentation

bool activateLanguage ( void  )
U32 addString ( const UTF8 *  str)
void deactivateLanguage ( void  )
void freeTable ( )
protected
const UTF8* getLangFile ( void  )
inline
const UTF8* getLangName ( void  )
inline
S32 getNumStrings ( void  )
inline
const UTF8 * getString ( U32  id)
bool isLoaded ( void  )
inline
bool load ( const UTF8 *  filename)
bool load ( Stream s)
bool save ( const UTF8 *  filename)
bool save ( Stream s)
void setLangFile ( const UTF8 *  langFile)
void setLangName ( const UTF8 *  newName)
void setString ( U32  id,
const UTF8 *  str 
)

Member Data Documentation

UTF8* mLangFile
protected
UTF8* mLangName
protected
Vector<UTF8 *> mStringTable
protected

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