Class TranslationService
Inheritance
TranslationService
Assembly: .dll
Syntax
public sealed class TranslationService
Properties
|
Edit this page
View Source
Language
Declaration
public static LanguageEnum Language { get; }
Property Value
Methods
|
Edit this page
View Source
GetInstance()
Declaration
public static TranslationService GetInstance()
Returns
|
Edit this page
View Source
GetText(string)
Declaration
public string GetText(string key)
Parameters
Type |
Name |
Description |
string |
key |
|
Returns
|
Edit this page
View Source
InitSetting()
Initializes application settings by setting the language and log format
based on the stored configuration.
Declaration
public static void InitSetting()
|
Edit this page
View Source
Replace(string)
Replaces each word in a given text with its corresponding translation.
Declaration
public string Replace(string text)
Parameters
Type |
Name |
Description |
string |
text |
The input text to be translated.
|
Returns
Type |
Description |
string |
The translated text with each word replaced.
|
|
Edit this page
View Source
SetLanguage(LanguageEnum)
Declaration
public static void SetLanguage(LanguageEnum language)
Parameters