LocalizationConfiguration.cs 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. using System.Collections.Generic;
  2. using Abp.Localization;
  3. namespace Abp.Configuration.Startup
  4. {
  5. /// <summary>
  6. /// Used for localization configurations.
  7. /// </summary>
  8. internal class LocalizationConfiguration : ILocalizationConfiguration
  9. {
  10. /// <inheritdoc/>
  11. public IList<LanguageInfo> Languages { get; }
  12. /// <inheritdoc/>
  13. public ILocalizationSourceList Sources { get; }
  14. /// <inheritdoc/>
  15. public bool IsEnabled { get; set; }
  16. /// <inheritdoc/>
  17. public bool ReturnGivenTextIfNotFound { get; set; }
  18. /// <inheritdoc/>
  19. public bool WrapGivenTextIfNotFound { get; set; }
  20. /// <inheritdoc/>
  21. public bool HumanizeTextIfNotFound { get; set; }
  22. public bool LogWarnMessageIfNotFound { get; set; }
  23. public LocalizationConfiguration()
  24. {
  25. Languages = new List<LanguageInfo>();
  26. Sources = new LocalizationSourceList();
  27. IsEnabled = true;
  28. ReturnGivenTextIfNotFound = true;
  29. WrapGivenTextIfNotFound = true;
  30. HumanizeTextIfNotFound = true;
  31. LogWarnMessageIfNotFound = true;
  32. }
  33. }
  34. }