public Form1() { Microsoft.Practices.ServiceLocation.ServiceLocator.SetLocatorProvider(new Microsoft.Practices.ServiceLocation.ServiceLocatorProvider( delegate() { var p = new Feng.DefaultServiceProvider(); p.EnableNHibernate(); p.SetDefaultService<ICache>(new HashtableCache()); p.SetDefaultService<IApplicationDirectory>(new WindowsDirectory()); return p; })); InitializeComponent(); m_webProxy.Encoding = System.Text.Encoding.UTF8; m_webProxy.ContentType = "application/json"; m_webProxy.Accept = "application/json"; btn当前作业_Click(btn当前作业, System.EventArgs.Empty); }
public Form1() { Microsoft.Practices.ServiceLocation.ServiceLocator.SetLocatorProvider(new Microsoft.Practices.ServiceLocation.ServiceLocatorProvider( delegate() { var p = new Feng.DefaultServiceProvider(); p.EnableNHibernate(); p.SetDefaultService <ICache>(new HashtableCache()); p.SetDefaultService <IApplicationDirectory>(new WindowsDirectory()); return(p); })); InitializeComponent(); m_webProxy.Encoding = System.Text.Encoding.UTF8; m_webProxy.ContentType = "application/json"; m_webProxy.Accept = "application/json"; btn当前作业_Click(btn当前作业, System.EventArgs.Empty); }