devtm.Translate


this project implement three providers for manage translation.

RessourceTranslationProvider
the translation are stored in ressource file

MockTranslateProvider
(only for the test)

SqlTranslationProvider
The translation are stored in sqlserver database.
Remark
if you want use the SqlTranslationProvider the database is describe in the project : devtm.Translate.Database.



if you want create your provider you must only inherit from TranslationProvider and implement the methods Set ans Set.

a translation is based on a context ContextTranslation

in the project this class have three properties.

culture, context, and key.

I will not explain why the property culture is here but you must to know by default the property is copied from :
System.Threading.Thread.CurrentThread.CurrentCulture

the key parameter is a unique key for find the translation.

the context parameter is a string value for define the context. A word can to have several meanings.
Meaning can change depending on the sentence.
by default is equals "Common"

You can use the provider with the service TranslationService.
If you create the instance without parameter the config file is used, so you need to add a section ProviderGlobalizationSection.




Last edited Nov 4, 2010 at 11:46 PM by gaelgael5, version 5

Comments

No comments yet.