des.util.localization

Simple Usage:

0. run program

0. copy and rename "translate/dir/base" to "translate/dir/lang.lt", where <lang> is language to translate

0. in each line in "translate/dir/lang.lt" write translation of line, for example hello : привет

0. profit

Members

Classes

BaseLocalization
class BaseLocalization
DictionaryLoaderException
class DictionaryLoaderException
DirDictionaryLoader
class DirDictionaryLoader

load localizations from directory

Translator
class Translator

singleton class for localization

Interfaces

DictionaryLoader
interface DictionaryLoader

localization handler

Localization
interface Localization
WordConverter
interface WordConverter

convert key to word

Properties

_
string _ [@property setter]

main function for localization when debug(printlocalizationkeys) output keys from pragma

Examples

1 setTranslatePath( "<translate/dir>" );
2 writeln( _!"hello" );
3 Translator.setLocalization( "ru" );
4 writeln( _!"hello" );
5 writeln( _!"world" );

Meta