public static SeifApplication AsProvider(string hostDomain, string protocol, string serializeMode, IDictionary <string, string> dictionary) { SeifApplication.AppEnv.GlobalConfiguration.ProviderConfiguration.ApiDomain = hostDomain; SeifApplication.AppEnv.GlobalConfiguration.ProviderConfiguration.ApiIpAddress = UriUtils.GetIpAddressByDomainName(hostDomain); SeifApplication.AppEnv.GlobalConfiguration.ProviderConfiguration.SerializeMode = serializeMode; SeifApplication.AppEnv.GlobalConfiguration.ProviderConfiguration.AddtionalFields = DictionaryUtils.ToConfig(dictionary); return(SeifApplication.AppEnv); }