public static WcfClientFactory GetFactory(string name)
        {
            lock (mFactory)
            {

                WcfClientFactory result;
                if (mFactory.TryGetValue(name, out result))
                    return result;
                //WcfItemsElementCollection item = mSection.Hosts.GetItemByKey(name);
                result = new WcfClientFactory();
                result.Connections.Clear();
                //foreach (WcfElement host in item)
                //{
                 
                //    result.Connections.Add(new ConnectItem { IPAddress = host.Ip, Port = host.Port });
                //}
                mFactory.Add(name, result);
                return result;
            }
        }
Ejemplo n.º 2
0
 public WcfMembershipProvider(string url, string token)
 {
     url = ConfigManager.ResolveValueSetting(url);
     _membershipService = WcfClientFactory.Create <IWcfSecurityService>(url);
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Constructor used by the internal configuration manager
 /// </summary>
 /// <param name="baseconf">Native instance of configuration system</param>
 internal ConfigWcfConfigSystem(IInternalConfigSystem baseconf)
 {
     _nativeConfigSystem = baseconf;
     _svc = WcfClientFactory.Create <IWcfConfigurationService>(CoreConfig.Configuration.WcfUrl);
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Specialized constructor so this system can be used outside of ConfigurationManager
 /// </summary>
 /// <param name="wcfConfigurationServiceUrl">Fully qualified url including .svc file</param>
 /// <param name="endPointConfigurationName">Specific section within WCF configuration</param>
 public ConfigWcfConfigSystem(string wcfConfigurationServiceUrl, string endPointConfigurationName)
 {
     _svc = WcfClientFactory.Create <IWcfConfigurationService>(wcfConfigurationServiceUrl, endPointConfigurationName);
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Constructor
 /// </summary>
 /// <param name="wcfConfigurationServiceUrl">Fully qualified url including .svc file</param>
 public ConfigWcfConfigSystem(string wcfConfigurationServiceUrl)
 {
     _svc = WcfClientFactory.Create <IWcfConfigurationService>(wcfConfigurationServiceUrl);
 }
Ejemplo n.º 6
0
 /// <summary>
 /// Creates the WCF client.
 /// </summary>
 private void CreateWcfClient()
 {
     WcfClientFactory.Create <T, K>(ClientConfig, this, ConnectionCallback);
 }
Ejemplo n.º 7
0
 public BaseService()
 {
     RegexFixSystemChar = new Regex(@"(!\\)\\\\([rnt])", RegexOptions.Compiled | RegexOptions.IgnoreCase);
     factory            = WcfClients.GetFactory("ProductDetail");
 }
Ejemplo n.º 8
0
 public BaseService()
 {
     RegexFixSystemChar = new Regex(@"(!\\)\\\\([rnt])", RegexOptions.Compiled | RegexOptions.IgnoreCase);
     factory = WcfClients.GetFactory("ProductDetail");
 }