using Autofac; using HybirdFrameworkServices.Netty; using HybirdFrameworkServices.System; using log4net; namespace WinFormStarter; public partial class Form1 : Form { private ILog _log = LogManager.GetLogger(typeof(Form1)); private SysUserServices _sysUserServices; public Form1(SysUserServices sysUserServices) { _sysUserServices = sysUserServices; InitializeComponent(); } private void button1_Click(object sender, EventArgs e) { Server server = AppInfo.Container.Resolve(); server.Begin(9000); } private void button2_Click(object sender, EventArgs e) { Server server = AppInfo.Container.Resolve(); server.Send(new byte[] { 1, 2, 3, 4, 9, 5, 6, 6, 7 }); } }