Esempio n. 1
0
        public static ILocalization Create([NotNull] IConfigBehavior behavior)
        {
            if (behavior is null)
            {
                throw new ArgumentNullException(nameof(behavior));
            }

            CurrentLocalization.ThrowIfAlreadyInitialized();
            CurrentLocalization.Current = new InternalLocalization(behavior);
            return(Current);
        }
Esempio n. 2
0
        public static ILocalization Create([NotNull] ILocalization localization)
        {
            if (localization is null)
            {
                throw new ArgumentNullException(nameof(localization));
            }

            CurrentLocalization.ThrowIfAlreadyInitialized();
            CurrentLocalization.Current = localization;
            return(Current);
        }
Esempio n. 3
0
 public static ILocalization Create(String path, ConfigType type, ConfigOptions options, ILocalizationBehaviour behaviour)
 {
     CurrentLocalization.ThrowIfAlreadyInitialized();
     CurrentLocalization.Current = new InternalLocalization(path, type, options, behaviour);
     return(Current);
 }