/// <summary> /// /// </summary> /// <param name="stringLocalizer"></param> public static void SetStringLocalizer(StringLocalizer stringLocalizer) { if (s_stringLocalizer != null) { throw new InvalidOperationException("Some strings have already been localized by another string localizer"); } s_stringLocalizer = stringLocalizer; }
/// <summary> /// /// </summary> /// <returns></returns> private static StringLocalizer GetStringLocalizer() { return(s_stringLocalizer ?? (s_stringLocalizer = new StringLocalizer())); }