初始化框架

master
smartwyy 7 months ago
parent 3b9965554b
commit 1634a07759

@ -83,21 +83,21 @@ namespace HybirdFrameworkCore.Autofac
}
else
{
Type? iInterface = type.GetInterface("HybirdFrameworkDriver.ChargerServer.IMsgHandler");
Type? iInterface = type.GetInterface("HybirdFrameworkDriver.TcpServer.IMsgHandler");
if (iInterface != null)
{
builder.RegisterType(type).As(iInterface).InstancePerDependency()
.PropertiesAutowired(PropertyWiringOptions.AllowCircularDependencies);
}
iInterface = type.GetInterface("HybirdFrameworkDriver.ChargerServer.IDecoder");
iInterface = type.GetInterface("HybirdFrameworkDriver.TcpServer.IDecoder");
if (iInterface != null)
{
builder.RegisterType(type).As(iInterface).InstancePerDependency()
.PropertiesAutowired(PropertyWiringOptions.AllowCircularDependencies);
}
iInterface = type.GetInterface("HybirdFrameworkDriver.ChargerServer.IEncoder");
iInterface = type.GetInterface("HybirdFrameworkDriver.TcpServer.IEncoder");
if (iInterface != null)
{
builder.RegisterType(type).As(iInterface).InstancePerDependency()

@ -1,5 +0,0 @@
namespace HybirdFrameworkDriver.ChargerServer;
public interface IDecoder
{
}

@ -1,6 +0,0 @@
namespace HybirdFrameworkDriver.ChargerServer;
public interface IEncoder
{
}

@ -1,7 +1,7 @@
using DotNetty.Common.Utilities;
using DotNetty.Transport.Channels;
namespace HybirdFrameworkDriver.ChargerServer;
namespace HybirdFrameworkDriver.TcpServer;
public static class ChannelUtils
{

@ -0,0 +1,5 @@
namespace HybirdFrameworkDriver.TcpServer;
public interface IDecoder
{
}

@ -0,0 +1,6 @@
namespace HybirdFrameworkDriver.TcpServer;
public interface IEncoder
{
}

@ -1,6 +1,6 @@
using DotNetty.Transport.Channels;
namespace HybirdFrameworkDriver.ChargerServer;
namespace HybirdFrameworkDriver.TcpServer;
public interface IMsgHandler
{

@ -2,7 +2,7 @@
using DotNetty.Transport.Channels;
using log4net;
namespace HybirdFrameworkDriver.ChargerServer;
namespace HybirdFrameworkDriver.TcpServer;
public class IoSession

@ -10,7 +10,7 @@ using HybirdFrameworkCore.Autofac;
using HybirdFrameworkCore.Autofac.Attribute;
using log4net;
namespace HybirdFrameworkDriver.ChargerServer
namespace HybirdFrameworkDriver.TcpServer
{
/// <summary>
/// netty server

@ -2,7 +2,7 @@
using HybirdFrameworkCore.Autofac.Attribute;
using log4net;
namespace HybirdFrameworkDriver.ChargerServer
namespace HybirdFrameworkDriver.TcpServer
{
[Scope("InstancePerDependency")]

@ -3,7 +3,7 @@ using DotNetty.Buffers;
using DotNetty.Transport.Channels;
using log4net;
namespace HybirdFrameworkDriver.ChargerServer;
namespace HybirdFrameworkDriver.TcpServer;
public class SessionMgr
{

@ -2,7 +2,7 @@
using DotNetty.Codecs;
using DotNetty.Transport.Channels;
using HybirdFrameworkCore.Autofac.Attribute;
using HybirdFrameworkDriver.ChargerServer;
using HybirdFrameworkDriver.TcpServer;
namespace HybirdFrameworkServices.Charger.Codec;

@ -2,7 +2,7 @@
using DotNetty.Codecs;
using DotNetty.Transport.Channels;
using HybirdFrameworkCore.Autofac.Attribute;
using HybirdFrameworkDriver.ChargerServer;
using HybirdFrameworkDriver.TcpServer;
namespace HybirdFrameworkServices.Charger.Codec;

@ -1,6 +1,6 @@
using DotNetty.Transport.Channels;
using HybirdFrameworkCore.Autofac.Attribute;
using HybirdFrameworkDriver.ChargerServer;
using HybirdFrameworkDriver.TcpServer;
using HybirdFrameworkServices.Charger.Msg;
namespace HybirdFrameworkServices.Charger.Handler;

@ -1,6 +1,6 @@
using DotNetty.Transport.Channels;
using HybirdFrameworkCore.Autofac.Attribute;
using HybirdFrameworkDriver.ChargerServer;
using HybirdFrameworkDriver.TcpServer;
namespace HybirdFrameworkServices.Charger.Handler;

@ -2,7 +2,7 @@ using Autofac;
using Autofac.Extensions.DependencyInjection;
using HybirdFrameworkCore.Autofac;
using HybirdFrameworkCore.Configuration;
using HybirdFrameworkDriver.ChargerServer;
using HybirdFrameworkDriver.TcpServer;
using SqlSugar;
using SqlSugar.IOC;

@ -1,4 +1,4 @@
using HybirdFrameworkDriver.ChargerServer;
using HybirdFrameworkDriver.TcpServer;
namespace WinFormStarter;

Loading…
Cancel
Save