From e80a03861c58fe8b47b5f57dc831f1ce6b18d720 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8B=A5=E6=B1=9D=E6=A3=8B=E8=8C=97?= <505554090@qq.com> Date: Wed, 27 Dec 2023 13:29:19 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0demo=E5=BC=95=E7=94=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../AdapterConsoleApp.csproj | 2 +- .../AdapterTesterConsoleApp.csproj | 2 +- .../CustomAdapterConsoleApp.csproj | 2 +- .../CustomFixedHeaderConsoleApp.csproj | 2 +- .../PackageAdapterConsoleApp.csproj | 2 +- .../PipelineConsoleApp.csproj | 12 ++--- .../TLVWinFormsApp/TLVWinFormsApp.csproj | 12 ++--- .../AccessRestrictionsConsoleApp.csproj | 12 ++--- .../DifferentProtocolConsoleApp.csproj | 12 ++--- .../HeartbeatConsoleApp.csproj | 2 +- .../LimitNumberOfConnectionsConsoleApp.csproj | 12 ++--- .../ThrottlingConsoleApp.csproj | 12 ++--- .../TrafficCounterConsoleApp.csproj | 12 ++--- .../ConsulConsoleApp/ConsulConsoleApp.csproj | 12 ++--- .../ServiceConsoleApp/ServiceConsoleApp.csproj | 12 ++--- .../WinFormsApp/WinFormsApp.csproj | 12 ++--- .../AppMessengerWinApp.csproj | 10 ++--- .../BytePoolConsoleApp.csproj | 12 ++--- .../Core/IocConsoleApp/IocConsoleApp.csproj | 6 +-- .../Log4netConsoleApp.csproj | 12 ++--- .../PackageConsoleApp.csproj | 12 ++--- .../PluginConsoleApp/PluginConsoleApp.csproj | 4 +- .../CustomDmtpActorConsoleApp.csproj | 2 +- .../DispatchProxyDmtpRpcConsoleApp.csproj | 2 +- .../DmtpChannelConsoleApp.csproj | 2 +- .../Dmtp/DmtpConsoleApp/DmtpConsoleApp.csproj | 2 +- .../DmtpRedisConsoleApp.csproj | 2 +- .../DmtpRpcClientApp/DmtpRpcClientApp.csproj | 12 ++--- .../DmtpRpcClientConsoleApp.csproj | 2 +- .../DmtpRpcServerConsoleApp.csproj | 2 +- .../DmtpWebApplication.csproj | 4 +- .../FileTransferConsoleApp.csproj | 2 +- .../GeneratorRpcProxyConsoleApp.csproj | 14 +++--- .../RealityProxyDmtpRpcConsoleApp.csproj | 2 +- .../RecommendRpcConsoleApp.csproj | 12 ++--- .../RemoteAccessApp/RemoteAccessApp.csproj | 12 ++--- .../RemoteStreamConsoleApp.csproj | 2 +- .../ReverseRpcConsoleApp.csproj | 12 ++--- .../RouterPackageConsoleApp.csproj | 2 +- .../RpcClassLibrary/RpcClassLibrary.csproj | 14 +++--- .../RpcFactoryConsoleApp.csproj | 12 ++--- .../RpcImplementationClassLibrary.csproj | 12 ++--- .../RpcStreamConsoleApp.csproj | 12 ++--- .../SerializationSelectorClassLibrary.csproj | 12 ++--- .../SerializationSelectorConsoleApp.csproj | 14 +++--- .../HostingWorkerService.csproj | 4 +- .../HttpClientConsoleApp.csproj | 2 +- .../HttpServiceConsoleApp.csproj | 2 +- ...ispatchProxyJsonRpcClientConsoleApp.csproj | 2 +- .../JsonRpcClientConsoleApp.csproj | 2 +- .../JsonRpcServiceConsoleApp.csproj | 2 +- .../ReverseJsonRpcConsoleApp.csproj | 2 +- .../ModbusMasterConsoleApp.csproj | 2 +- .../ModbusObjectConsoleApp.csproj | 2 +- .../Modbus/ModbusObjectConsoleApp/Program.cs | 18 +++++--- .../ModbusSlaveConsoleApp.csproj | 2 +- .../Modbus/ModbusSlaveConsoleApp/Program.cs | 45 ++++++++++++++----- .../NATServiceConsoleApp.csproj | 12 ++--- .../NamedPipeClientConsoleApp.csproj | 2 +- .../NamedPipeServiceConsoleApp.csproj | 2 +- .../NamedPipeStressTestingConsoleApp.csproj | 2 +- .../GenerateProxyFromServerConsoleApp.csproj | 2 +- .../SerialPortClientConsoleApp.csproj | 2 +- .../TcpCommandLineConsoleApp.csproj | 12 ++--- .../Tcp/TcpConsoleApp/TcpConsoleApp.csproj | 4 +- .../TcpServiceForWebApi.csproj | 14 +++--- .../TcpWaitingClientWinFormsApp.csproj | 2 +- .../UdpBroadcastConsoleApp.csproj | 12 ++--- examples/Udp/UdpDemoApp/UdpDemoApp.csproj | 12 ++--- .../ScreenUdpReceiver.csproj | 2 +- .../ScreenUdpSender/ScreenUdpSender.csproj | 2 +- .../UnityServerConsoleApp.csproj | 2 +- .../DispatchProxyWebApiConsoleApp.csproj | 2 +- .../WebApiClientApp/WebApiClientApp.csproj | 2 +- .../WebApiServer/WebApiServerApp.csproj | 4 +- .../AsyncWebSocketConsoleApp.csproj | 2 +- .../WebSocketConsoleApp.csproj | 4 +- ...DispatchProxyXmlRpcClientConsoleApp.csproj | 2 +- .../XmlRpcClientApp/XmlRpcClientApp.csproj | 2 +- .../XmlRpcServerApp/XmlRpcServerApp.csproj | 2 +- handbook/docs/generichost.mdx | 14 ------ 81 files changed, 286 insertions(+), 269 deletions(-) diff --git a/examples/Adapter/AdapterConsoleApp/AdapterConsoleApp.csproj b/examples/Adapter/AdapterConsoleApp/AdapterConsoleApp.csproj index fa3708fba..e116420a0 100644 --- a/examples/Adapter/AdapterConsoleApp/AdapterConsoleApp.csproj +++ b/examples/Adapter/AdapterConsoleApp/AdapterConsoleApp.csproj @@ -6,6 +6,6 @@ - + diff --git a/examples/Adapter/AdapterTesterConsoleApp/AdapterTesterConsoleApp.csproj b/examples/Adapter/AdapterTesterConsoleApp/AdapterTesterConsoleApp.csproj index 61d879e1d..ddbc5a4c2 100644 --- a/examples/Adapter/AdapterTesterConsoleApp/AdapterTesterConsoleApp.csproj +++ b/examples/Adapter/AdapterTesterConsoleApp/AdapterTesterConsoleApp.csproj @@ -7,6 +7,6 @@ - + diff --git a/examples/Adapter/CustomAdapterConsoleApp/CustomAdapterConsoleApp.csproj b/examples/Adapter/CustomAdapterConsoleApp/CustomAdapterConsoleApp.csproj index 489b8a291..43aa79467 100644 --- a/examples/Adapter/CustomAdapterConsoleApp/CustomAdapterConsoleApp.csproj +++ b/examples/Adapter/CustomAdapterConsoleApp/CustomAdapterConsoleApp.csproj @@ -8,6 +8,6 @@ - + diff --git a/examples/Adapter/CustomFixedHeaderConsoleApp/CustomFixedHeaderConsoleApp.csproj b/examples/Adapter/CustomFixedHeaderConsoleApp/CustomFixedHeaderConsoleApp.csproj index 489b8a291..43aa79467 100644 --- a/examples/Adapter/CustomFixedHeaderConsoleApp/CustomFixedHeaderConsoleApp.csproj +++ b/examples/Adapter/CustomFixedHeaderConsoleApp/CustomFixedHeaderConsoleApp.csproj @@ -8,6 +8,6 @@ - + diff --git a/examples/Adapter/PackageAdapterConsoleApp/PackageAdapterConsoleApp.csproj b/examples/Adapter/PackageAdapterConsoleApp/PackageAdapterConsoleApp.csproj index bc415a5c2..af0fd6392 100644 --- a/examples/Adapter/PackageAdapterConsoleApp/PackageAdapterConsoleApp.csproj +++ b/examples/Adapter/PackageAdapterConsoleApp/PackageAdapterConsoleApp.csproj @@ -8,6 +8,6 @@ - + diff --git a/examples/Adapter/PipelineConsoleApp/PipelineConsoleApp.csproj b/examples/Adapter/PipelineConsoleApp/PipelineConsoleApp.csproj index a648d707f..925f11709 100644 --- a/examples/Adapter/PipelineConsoleApp/PipelineConsoleApp.csproj +++ b/examples/Adapter/PipelineConsoleApp/PipelineConsoleApp.csproj @@ -8,12 +8,12 @@ - - - - - - + + + + + + diff --git a/examples/Adapter/TLVWinFormsApp/TLVWinFormsApp.csproj b/examples/Adapter/TLVWinFormsApp/TLVWinFormsApp.csproj index 43a29f01f..cb5de8f58 100644 --- a/examples/Adapter/TLVWinFormsApp/TLVWinFormsApp.csproj +++ b/examples/Adapter/TLVWinFormsApp/TLVWinFormsApp.csproj @@ -9,12 +9,12 @@ - - - - - - + + + + + + \ No newline at end of file diff --git a/examples/BlogsDemos/AccessRestrictionsConsoleApp/AccessRestrictionsConsoleApp.csproj b/examples/BlogsDemos/AccessRestrictionsConsoleApp/AccessRestrictionsConsoleApp.csproj index a648d707f..925f11709 100644 --- a/examples/BlogsDemos/AccessRestrictionsConsoleApp/AccessRestrictionsConsoleApp.csproj +++ b/examples/BlogsDemos/AccessRestrictionsConsoleApp/AccessRestrictionsConsoleApp.csproj @@ -8,12 +8,12 @@ - - - - - - + + + + + + diff --git a/examples/BlogsDemos/DifferentProtocolConsoleApp/DifferentProtocolConsoleApp.csproj b/examples/BlogsDemos/DifferentProtocolConsoleApp/DifferentProtocolConsoleApp.csproj index a648d707f..925f11709 100644 --- a/examples/BlogsDemos/DifferentProtocolConsoleApp/DifferentProtocolConsoleApp.csproj +++ b/examples/BlogsDemos/DifferentProtocolConsoleApp/DifferentProtocolConsoleApp.csproj @@ -8,12 +8,12 @@ - - - - - - + + + + + + diff --git a/examples/BlogsDemos/HeartbeatConsoleApp/HeartbeatConsoleApp.csproj b/examples/BlogsDemos/HeartbeatConsoleApp/HeartbeatConsoleApp.csproj index b3ac4d169..c8ce41bc9 100644 --- a/examples/BlogsDemos/HeartbeatConsoleApp/HeartbeatConsoleApp.csproj +++ b/examples/BlogsDemos/HeartbeatConsoleApp/HeartbeatConsoleApp.csproj @@ -6,6 +6,6 @@ - + diff --git a/examples/BlogsDemos/LimitNumberOfConnectionsConsoleApp/LimitNumberOfConnectionsConsoleApp.csproj b/examples/BlogsDemos/LimitNumberOfConnectionsConsoleApp/LimitNumberOfConnectionsConsoleApp.csproj index 63a559638..5fcd127f8 100644 --- a/examples/BlogsDemos/LimitNumberOfConnectionsConsoleApp/LimitNumberOfConnectionsConsoleApp.csproj +++ b/examples/BlogsDemos/LimitNumberOfConnectionsConsoleApp/LimitNumberOfConnectionsConsoleApp.csproj @@ -6,12 +6,12 @@ - - - - - - + + + + + + diff --git a/examples/BlogsDemos/ThrottlingConsoleApp/ThrottlingConsoleApp.csproj b/examples/BlogsDemos/ThrottlingConsoleApp/ThrottlingConsoleApp.csproj index 63a559638..5fcd127f8 100644 --- a/examples/BlogsDemos/ThrottlingConsoleApp/ThrottlingConsoleApp.csproj +++ b/examples/BlogsDemos/ThrottlingConsoleApp/ThrottlingConsoleApp.csproj @@ -6,12 +6,12 @@ - - - - - - + + + + + + diff --git a/examples/BlogsDemos/TrafficCounterConsoleApp/TrafficCounterConsoleApp.csproj b/examples/BlogsDemos/TrafficCounterConsoleApp/TrafficCounterConsoleApp.csproj index 1fd8f54c7..be27d9647 100644 --- a/examples/BlogsDemos/TrafficCounterConsoleApp/TrafficCounterConsoleApp.csproj +++ b/examples/BlogsDemos/TrafficCounterConsoleApp/TrafficCounterConsoleApp.csproj @@ -6,11 +6,11 @@ - - - - - - + + + + + + diff --git a/examples/Consul集群示例/ConsulConsoleApp/ConsulConsoleApp.csproj b/examples/Consul集群示例/ConsulConsoleApp/ConsulConsoleApp.csproj index 522fbe4ed..4c6c16474 100644 --- a/examples/Consul集群示例/ConsulConsoleApp/ConsulConsoleApp.csproj +++ b/examples/Consul集群示例/ConsulConsoleApp/ConsulConsoleApp.csproj @@ -7,12 +7,12 @@ - - - - - - + + + + + + diff --git a/examples/Consul集群示例/TouchRpc Consul集群/ServiceConsoleApp/ServiceConsoleApp.csproj b/examples/Consul集群示例/TouchRpc Consul集群/ServiceConsoleApp/ServiceConsoleApp.csproj index 522fbe4ed..4c6c16474 100644 --- a/examples/Consul集群示例/TouchRpc Consul集群/ServiceConsoleApp/ServiceConsoleApp.csproj +++ b/examples/Consul集群示例/TouchRpc Consul集群/ServiceConsoleApp/ServiceConsoleApp.csproj @@ -7,12 +7,12 @@ - - - - - - + + + + + + diff --git a/examples/Consul集群示例/TouchRpc Consul集群/WinFormsApp/WinFormsApp.csproj b/examples/Consul集群示例/TouchRpc Consul集群/WinFormsApp/WinFormsApp.csproj index 79641f9f7..b20accb45 100644 --- a/examples/Consul集群示例/TouchRpc Consul集群/WinFormsApp/WinFormsApp.csproj +++ b/examples/Consul集群示例/TouchRpc Consul集群/WinFormsApp/WinFormsApp.csproj @@ -8,12 +8,12 @@ - - - - - - + + + + + + \ No newline at end of file diff --git a/examples/Core/AppMessengerWinApp/AppMessengerWinApp.csproj b/examples/Core/AppMessengerWinApp/AppMessengerWinApp.csproj index 80210b9e0..5cf2d004c 100644 --- a/examples/Core/AppMessengerWinApp/AppMessengerWinApp.csproj +++ b/examples/Core/AppMessengerWinApp/AppMessengerWinApp.csproj @@ -9,11 +9,11 @@ - - - - - + + + + + \ No newline at end of file diff --git a/examples/Core/BytePoolConsoleApp/BytePoolConsoleApp.csproj b/examples/Core/BytePoolConsoleApp/BytePoolConsoleApp.csproj index a622c824a..68ca205d1 100644 --- a/examples/Core/BytePoolConsoleApp/BytePoolConsoleApp.csproj +++ b/examples/Core/BytePoolConsoleApp/BytePoolConsoleApp.csproj @@ -5,11 +5,11 @@ net6.0 - - - - - - + + + + + + diff --git a/examples/Core/IocConsoleApp/IocConsoleApp.csproj b/examples/Core/IocConsoleApp/IocConsoleApp.csproj index 345fb295f..180360707 100644 --- a/examples/Core/IocConsoleApp/IocConsoleApp.csproj +++ b/examples/Core/IocConsoleApp/IocConsoleApp.csproj @@ -7,12 +7,12 @@ - + all runtime; build; native; contentfiles; analyzers; buildtransitive - - + + diff --git a/examples/Core/Log4netConsoleApp/Log4netConsoleApp.csproj b/examples/Core/Log4netConsoleApp/Log4netConsoleApp.csproj index f72a01929..6825c5c7a 100644 --- a/examples/Core/Log4netConsoleApp/Log4netConsoleApp.csproj +++ b/examples/Core/Log4netConsoleApp/Log4netConsoleApp.csproj @@ -9,12 +9,12 @@ - - - - - - + + + + + + diff --git a/examples/Core/PackageConsoleApp/PackageConsoleApp.csproj b/examples/Core/PackageConsoleApp/PackageConsoleApp.csproj index 5ad22fbf5..5cd7e4fa7 100644 --- a/examples/Core/PackageConsoleApp/PackageConsoleApp.csproj +++ b/examples/Core/PackageConsoleApp/PackageConsoleApp.csproj @@ -6,11 +6,11 @@ enable - - - - - - + + + + + + diff --git a/examples/Core/PluginConsoleApp/PluginConsoleApp.csproj b/examples/Core/PluginConsoleApp/PluginConsoleApp.csproj index a20b6c2e3..cc336fc51 100644 --- a/examples/Core/PluginConsoleApp/PluginConsoleApp.csproj +++ b/examples/Core/PluginConsoleApp/PluginConsoleApp.csproj @@ -6,10 +6,10 @@ - + all runtime; build; native; contentfiles; analyzers; buildtransitive - + diff --git a/examples/Dmtp/CustomDmtpActorConsoleApp/CustomDmtpActorConsoleApp.csproj b/examples/Dmtp/CustomDmtpActorConsoleApp/CustomDmtpActorConsoleApp.csproj index e182bfe7f..44185cfa1 100644 --- a/examples/Dmtp/CustomDmtpActorConsoleApp/CustomDmtpActorConsoleApp.csproj +++ b/examples/Dmtp/CustomDmtpActorConsoleApp/CustomDmtpActorConsoleApp.csproj @@ -7,6 +7,6 @@ - + diff --git a/examples/Dmtp/DispatchProxyDmtpRpcConsoleApp/DispatchProxyDmtpRpcConsoleApp.csproj b/examples/Dmtp/DispatchProxyDmtpRpcConsoleApp/DispatchProxyDmtpRpcConsoleApp.csproj index d2cefa2cb..9f620bfe1 100644 --- a/examples/Dmtp/DispatchProxyDmtpRpcConsoleApp/DispatchProxyDmtpRpcConsoleApp.csproj +++ b/examples/Dmtp/DispatchProxyDmtpRpcConsoleApp/DispatchProxyDmtpRpcConsoleApp.csproj @@ -8,6 +8,6 @@ - + diff --git a/examples/Dmtp/DmtpChannelConsoleApp/DmtpChannelConsoleApp.csproj b/examples/Dmtp/DmtpChannelConsoleApp/DmtpChannelConsoleApp.csproj index d2cefa2cb..9f620bfe1 100644 --- a/examples/Dmtp/DmtpChannelConsoleApp/DmtpChannelConsoleApp.csproj +++ b/examples/Dmtp/DmtpChannelConsoleApp/DmtpChannelConsoleApp.csproj @@ -8,6 +8,6 @@ - + diff --git a/examples/Dmtp/DmtpConsoleApp/DmtpConsoleApp.csproj b/examples/Dmtp/DmtpConsoleApp/DmtpConsoleApp.csproj index 3f9b11e16..fdd6640ab 100644 --- a/examples/Dmtp/DmtpConsoleApp/DmtpConsoleApp.csproj +++ b/examples/Dmtp/DmtpConsoleApp/DmtpConsoleApp.csproj @@ -8,7 +8,7 @@ - + diff --git a/examples/Dmtp/DmtpRedisConsoleApp/DmtpRedisConsoleApp.csproj b/examples/Dmtp/DmtpRedisConsoleApp/DmtpRedisConsoleApp.csproj index 8de513bd2..8432a7875 100644 --- a/examples/Dmtp/DmtpRedisConsoleApp/DmtpRedisConsoleApp.csproj +++ b/examples/Dmtp/DmtpRedisConsoleApp/DmtpRedisConsoleApp.csproj @@ -8,7 +8,7 @@ - + diff --git a/examples/Dmtp/DmtpRpcClientApp/DmtpRpcClientApp.csproj b/examples/Dmtp/DmtpRpcClientApp/DmtpRpcClientApp.csproj index b6df27208..8692282ad 100644 --- a/examples/Dmtp/DmtpRpcClientApp/DmtpRpcClientApp.csproj +++ b/examples/Dmtp/DmtpRpcClientApp/DmtpRpcClientApp.csproj @@ -6,11 +6,11 @@ - - - - - - + + + + + + \ No newline at end of file diff --git a/examples/Dmtp/DmtpRpcClientConsoleApp/DmtpRpcClientConsoleApp.csproj b/examples/Dmtp/DmtpRpcClientConsoleApp/DmtpRpcClientConsoleApp.csproj index c53228cca..191085794 100644 --- a/examples/Dmtp/DmtpRpcClientConsoleApp/DmtpRpcClientConsoleApp.csproj +++ b/examples/Dmtp/DmtpRpcClientConsoleApp/DmtpRpcClientConsoleApp.csproj @@ -12,6 +12,6 @@ - + diff --git a/examples/Dmtp/DmtpRpcServerConsoleApp/DmtpRpcServerConsoleApp.csproj b/examples/Dmtp/DmtpRpcServerConsoleApp/DmtpRpcServerConsoleApp.csproj index 8de513bd2..8432a7875 100644 --- a/examples/Dmtp/DmtpRpcServerConsoleApp/DmtpRpcServerConsoleApp.csproj +++ b/examples/Dmtp/DmtpRpcServerConsoleApp/DmtpRpcServerConsoleApp.csproj @@ -8,7 +8,7 @@ - + diff --git a/examples/Dmtp/DmtpWebApplication/DmtpWebApplication.csproj b/examples/Dmtp/DmtpWebApplication/DmtpWebApplication.csproj index bed1cfc64..b6d1dcecf 100644 --- a/examples/Dmtp/DmtpWebApplication/DmtpWebApplication.csproj +++ b/examples/Dmtp/DmtpWebApplication/DmtpWebApplication.csproj @@ -7,8 +7,8 @@ - - + + diff --git a/examples/Dmtp/FileTransferConsoleApp/FileTransferConsoleApp.csproj b/examples/Dmtp/FileTransferConsoleApp/FileTransferConsoleApp.csproj index bd52bbd16..d63a85bfa 100644 --- a/examples/Dmtp/FileTransferConsoleApp/FileTransferConsoleApp.csproj +++ b/examples/Dmtp/FileTransferConsoleApp/FileTransferConsoleApp.csproj @@ -35,6 +35,6 @@ --> - + diff --git a/examples/Dmtp/GeneratorRpcProxyConsoleApp/GeneratorRpcProxyConsoleApp.csproj b/examples/Dmtp/GeneratorRpcProxyConsoleApp/GeneratorRpcProxyConsoleApp.csproj index 5d9921508..1061f3607 100644 --- a/examples/Dmtp/GeneratorRpcProxyConsoleApp/GeneratorRpcProxyConsoleApp.csproj +++ b/examples/Dmtp/GeneratorRpcProxyConsoleApp/GeneratorRpcProxyConsoleApp.csproj @@ -8,16 +8,16 @@ - + all runtime; build; native; contentfiles; analyzers; buildtransitive - - - - - - + + + + + + diff --git a/examples/Dmtp/RealityProxyDmtpRpcConsoleApp/RealityProxyDmtpRpcConsoleApp.csproj b/examples/Dmtp/RealityProxyDmtpRpcConsoleApp/RealityProxyDmtpRpcConsoleApp.csproj index 3064b2a55..d2300556a 100644 --- a/examples/Dmtp/RealityProxyDmtpRpcConsoleApp/RealityProxyDmtpRpcConsoleApp.csproj +++ b/examples/Dmtp/RealityProxyDmtpRpcConsoleApp/RealityProxyDmtpRpcConsoleApp.csproj @@ -6,7 +6,7 @@ - + diff --git a/examples/Dmtp/RecommendRpcConsoleApp/RecommendRpcConsoleApp.csproj b/examples/Dmtp/RecommendRpcConsoleApp/RecommendRpcConsoleApp.csproj index f9a425943..0daa676c2 100644 --- a/examples/Dmtp/RecommendRpcConsoleApp/RecommendRpcConsoleApp.csproj +++ b/examples/Dmtp/RecommendRpcConsoleApp/RecommendRpcConsoleApp.csproj @@ -8,12 +8,12 @@ - - - - - - + + + + + + diff --git a/examples/Dmtp/RemoteAccessApp/RemoteAccessApp.csproj b/examples/Dmtp/RemoteAccessApp/RemoteAccessApp.csproj index d3e57b4d7..7f7f1b434 100644 --- a/examples/Dmtp/RemoteAccessApp/RemoteAccessApp.csproj +++ b/examples/Dmtp/RemoteAccessApp/RemoteAccessApp.csproj @@ -10,11 +10,11 @@ - - - - - - + + + + + + \ No newline at end of file diff --git a/examples/Dmtp/RemoteStreamConsoleApp/RemoteStreamConsoleApp.csproj b/examples/Dmtp/RemoteStreamConsoleApp/RemoteStreamConsoleApp.csproj index 3f9b11e16..fdd6640ab 100644 --- a/examples/Dmtp/RemoteStreamConsoleApp/RemoteStreamConsoleApp.csproj +++ b/examples/Dmtp/RemoteStreamConsoleApp/RemoteStreamConsoleApp.csproj @@ -8,7 +8,7 @@ - + diff --git a/examples/Dmtp/ReverseRpcConsoleApp/ReverseRpcConsoleApp.csproj b/examples/Dmtp/ReverseRpcConsoleApp/ReverseRpcConsoleApp.csproj index 5a1256b9c..097529463 100644 --- a/examples/Dmtp/ReverseRpcConsoleApp/ReverseRpcConsoleApp.csproj +++ b/examples/Dmtp/ReverseRpcConsoleApp/ReverseRpcConsoleApp.csproj @@ -6,11 +6,11 @@ - - - - - - + + + + + + diff --git a/examples/Dmtp/RouterPackageConsoleApp/RouterPackageConsoleApp.csproj b/examples/Dmtp/RouterPackageConsoleApp/RouterPackageConsoleApp.csproj index aef6e6a44..19f98c63a 100644 --- a/examples/Dmtp/RouterPackageConsoleApp/RouterPackageConsoleApp.csproj +++ b/examples/Dmtp/RouterPackageConsoleApp/RouterPackageConsoleApp.csproj @@ -7,6 +7,6 @@ - + diff --git a/examples/Dmtp/RpcClassLibrary/RpcClassLibrary.csproj b/examples/Dmtp/RpcClassLibrary/RpcClassLibrary.csproj index b98ea087a..1cc561a2f 100644 --- a/examples/Dmtp/RpcClassLibrary/RpcClassLibrary.csproj +++ b/examples/Dmtp/RpcClassLibrary/RpcClassLibrary.csproj @@ -5,16 +5,16 @@ - + all runtime; build; native; contentfiles; analyzers; buildtransitive - - - - - - + + + + + + diff --git a/examples/Dmtp/RpcFactoryConsoleApp/RpcFactoryConsoleApp.csproj b/examples/Dmtp/RpcFactoryConsoleApp/RpcFactoryConsoleApp.csproj index 441f27537..93c90f746 100644 --- a/examples/Dmtp/RpcFactoryConsoleApp/RpcFactoryConsoleApp.csproj +++ b/examples/Dmtp/RpcFactoryConsoleApp/RpcFactoryConsoleApp.csproj @@ -8,12 +8,12 @@ - - - - - - + + + + + + diff --git a/examples/Dmtp/RpcImplementationClassLibrary/RpcImplementationClassLibrary.csproj b/examples/Dmtp/RpcImplementationClassLibrary/RpcImplementationClassLibrary.csproj index 3639df332..21a46a1a8 100644 --- a/examples/Dmtp/RpcImplementationClassLibrary/RpcImplementationClassLibrary.csproj +++ b/examples/Dmtp/RpcImplementationClassLibrary/RpcImplementationClassLibrary.csproj @@ -5,12 +5,12 @@ - - - - - - + + + + + + diff --git a/examples/Dmtp/RpcStreamConsoleApp/RpcStreamConsoleApp.csproj b/examples/Dmtp/RpcStreamConsoleApp/RpcStreamConsoleApp.csproj index a648d707f..925f11709 100644 --- a/examples/Dmtp/RpcStreamConsoleApp/RpcStreamConsoleApp.csproj +++ b/examples/Dmtp/RpcStreamConsoleApp/RpcStreamConsoleApp.csproj @@ -8,12 +8,12 @@ - - - - - - + + + + + + diff --git a/examples/Dmtp/SerializationSelectorClassLibrary/SerializationSelectorClassLibrary.csproj b/examples/Dmtp/SerializationSelectorClassLibrary/SerializationSelectorClassLibrary.csproj index de4093b51..ded42d258 100644 --- a/examples/Dmtp/SerializationSelectorClassLibrary/SerializationSelectorClassLibrary.csproj +++ b/examples/Dmtp/SerializationSelectorClassLibrary/SerializationSelectorClassLibrary.csproj @@ -6,12 +6,12 @@ - - - - - - + + + + + + diff --git a/examples/Dmtp/SerializationSelectorConsoleApp/SerializationSelectorConsoleApp.csproj b/examples/Dmtp/SerializationSelectorConsoleApp/SerializationSelectorConsoleApp.csproj index 68bb71124..017710b1f 100644 --- a/examples/Dmtp/SerializationSelectorConsoleApp/SerializationSelectorConsoleApp.csproj +++ b/examples/Dmtp/SerializationSelectorConsoleApp/SerializationSelectorConsoleApp.csproj @@ -7,16 +7,16 @@ enable - + all runtime; build; native; contentfiles; analyzers; buildtransitive - - - - - - + + + + + + diff --git a/examples/Hosting/HostingWorkerService/HostingWorkerService.csproj b/examples/Hosting/HostingWorkerService/HostingWorkerService.csproj index baa9a8ba4..c33d8898a 100644 --- a/examples/Hosting/HostingWorkerService/HostingWorkerService.csproj +++ b/examples/Hosting/HostingWorkerService/HostingWorkerService.csproj @@ -9,7 +9,7 @@ - - + + diff --git a/examples/Http/HttpClientConsoleApp/HttpClientConsoleApp.csproj b/examples/Http/HttpClientConsoleApp/HttpClientConsoleApp.csproj index a8fcb8d5b..9dc2f99dd 100644 --- a/examples/Http/HttpClientConsoleApp/HttpClientConsoleApp.csproj +++ b/examples/Http/HttpClientConsoleApp/HttpClientConsoleApp.csproj @@ -7,6 +7,6 @@ - + diff --git a/examples/Http/HttpServiceConsoleApp/HttpServiceConsoleApp.csproj b/examples/Http/HttpServiceConsoleApp/HttpServiceConsoleApp.csproj index 7eb3b3f9f..a8a9aca7c 100644 --- a/examples/Http/HttpServiceConsoleApp/HttpServiceConsoleApp.csproj +++ b/examples/Http/HttpServiceConsoleApp/HttpServiceConsoleApp.csproj @@ -6,7 +6,7 @@ - + diff --git a/examples/JsonRpc/DispatchProxyJsonRpcClientConsoleApp/DispatchProxyJsonRpcClientConsoleApp.csproj b/examples/JsonRpc/DispatchProxyJsonRpcClientConsoleApp/DispatchProxyJsonRpcClientConsoleApp.csproj index ad44daadb..869952fd4 100644 --- a/examples/JsonRpc/DispatchProxyJsonRpcClientConsoleApp/DispatchProxyJsonRpcClientConsoleApp.csproj +++ b/examples/JsonRpc/DispatchProxyJsonRpcClientConsoleApp/DispatchProxyJsonRpcClientConsoleApp.csproj @@ -8,6 +8,6 @@ - + diff --git a/examples/JsonRpc/JsonRpcClientConsoleApp/JsonRpcClientConsoleApp.csproj b/examples/JsonRpc/JsonRpcClientConsoleApp/JsonRpcClientConsoleApp.csproj index 442bfe556..b05a65500 100644 --- a/examples/JsonRpc/JsonRpcClientConsoleApp/JsonRpcClientConsoleApp.csproj +++ b/examples/JsonRpc/JsonRpcClientConsoleApp/JsonRpcClientConsoleApp.csproj @@ -12,6 +12,6 @@ - + diff --git a/examples/JsonRpc/JsonRpcConsoleApp/JsonRpcServiceConsoleApp.csproj b/examples/JsonRpc/JsonRpcConsoleApp/JsonRpcServiceConsoleApp.csproj index 31845d57e..67432a592 100644 --- a/examples/JsonRpc/JsonRpcConsoleApp/JsonRpcServiceConsoleApp.csproj +++ b/examples/JsonRpc/JsonRpcConsoleApp/JsonRpcServiceConsoleApp.csproj @@ -6,6 +6,6 @@ - + diff --git a/examples/JsonRpc/ReverseJsonRpcConsoleApp/ReverseJsonRpcConsoleApp.csproj b/examples/JsonRpc/ReverseJsonRpcConsoleApp/ReverseJsonRpcConsoleApp.csproj index 586a41c97..6e995c4ce 100644 --- a/examples/JsonRpc/ReverseJsonRpcConsoleApp/ReverseJsonRpcConsoleApp.csproj +++ b/examples/JsonRpc/ReverseJsonRpcConsoleApp/ReverseJsonRpcConsoleApp.csproj @@ -8,6 +8,6 @@ - + diff --git a/examples/Modbus/ModbusMasterConsoleApp/ModbusMasterConsoleApp.csproj b/examples/Modbus/ModbusMasterConsoleApp/ModbusMasterConsoleApp.csproj index 936f3a84a..01f75d3a2 100644 --- a/examples/Modbus/ModbusMasterConsoleApp/ModbusMasterConsoleApp.csproj +++ b/examples/Modbus/ModbusMasterConsoleApp/ModbusMasterConsoleApp.csproj @@ -8,7 +8,7 @@ - + diff --git a/examples/Modbus/ModbusObjectConsoleApp/ModbusObjectConsoleApp.csproj b/examples/Modbus/ModbusObjectConsoleApp/ModbusObjectConsoleApp.csproj index d7316b399..f24fe350e 100644 --- a/examples/Modbus/ModbusObjectConsoleApp/ModbusObjectConsoleApp.csproj +++ b/examples/Modbus/ModbusObjectConsoleApp/ModbusObjectConsoleApp.csproj @@ -8,7 +8,7 @@ - + diff --git a/examples/Modbus/ModbusObjectConsoleApp/Program.cs b/examples/Modbus/ModbusObjectConsoleApp/Program.cs index 6b31c7229..b0c9a8552 100644 --- a/examples/Modbus/ModbusObjectConsoleApp/Program.cs +++ b/examples/Modbus/ModbusObjectConsoleApp/Program.cs @@ -50,13 +50,19 @@ namespace ModbusObjectConsoleApp service.Setup(new TouchSocketConfig() //监听端口 .SetListenIPHosts(7808) - //设置数据存储区,即线圈、离散输入、保持寄存器、输入寄存器 - .SetModbusDataLocater(new ModbusDataLocater(10, 10, 10, 10) + .ConfigurePlugins(a => { - Coils = new DataPartition(1000, new bool[10]), - DiscreteInputs = new DataPartition(1000, new bool[10]), - HoldingRegisters = new DataPartition(1000, new byte[20]), - InputRegisters = new DataPartition(1000, new byte[20]) + a.AddModbusSlavePoint()//添加一个从站站点 + .SetSlaveId(1)//设置站点号 + .UseIgnoreSlaveId()//忽略站号验证 + .SetModbusDataLocater(new ModbusDataLocater()//设置数据区 + { + //下列配置表示,起始地址从1000开始,10个长度 + Coils = new BooleanDataPartition(1000, 10), + DiscreteInputs = new BooleanDataPartition(1000, 10), + HoldingRegisters = new ShortDataPartition(1000, 10), + InputRegisters = new ShortDataPartition(1000, 10) + }); }) ); service.Start(); diff --git a/examples/Modbus/ModbusSlaveConsoleApp/ModbusSlaveConsoleApp.csproj b/examples/Modbus/ModbusSlaveConsoleApp/ModbusSlaveConsoleApp.csproj index d7316b399..f24fe350e 100644 --- a/examples/Modbus/ModbusSlaveConsoleApp/ModbusSlaveConsoleApp.csproj +++ b/examples/Modbus/ModbusSlaveConsoleApp/ModbusSlaveConsoleApp.csproj @@ -8,7 +8,7 @@ - + diff --git a/examples/Modbus/ModbusSlaveConsoleApp/Program.cs b/examples/Modbus/ModbusSlaveConsoleApp/Program.cs index f156058ef..94d790971 100644 --- a/examples/Modbus/ModbusSlaveConsoleApp/Program.cs +++ b/examples/Modbus/ModbusSlaveConsoleApp/Program.cs @@ -28,8 +28,13 @@ namespace ModbusSlaveConsoleApp service.Setup(new TouchSocketConfig() //监听端口 .SetListenIPHosts(7808) - //设置数据存储区,即线圈、离散输入、保持寄存器、输入寄存器 - .SetModbusDataLocater(new ModbusDataLocater(10, 10, 10, 10)) + .ConfigurePlugins(a => + { + a.AddModbusSlavePoint()//添加一个从站站点 + .SetSlaveId(1)//设置站点号 + .UseIgnoreSlaveId()//忽略站号验证 + .SetModbusDataLocater(new ModbusDataLocater(10,10,10,10));//设置数据区 + }) ); service.Start(); Console.WriteLine("服务已启动"); @@ -42,8 +47,13 @@ namespace ModbusSlaveConsoleApp service.Setup(new TouchSocketConfig() //监听端口 .SetListenIPHosts(7810) - //设置数据存储区,即线圈、离散输入、保持寄存器、输入寄存器 - .SetModbusDataLocater(new ModbusDataLocater(10, 10, 10, 10)) + .ConfigurePlugins(a => + { + a.AddModbusSlavePoint()//添加一个从站站点 + .SetSlaveId(1)//设置站点号 + .UseIgnoreSlaveId()//忽略站号验证 + .SetModbusDataLocater(new ModbusDataLocater(10, 10, 10, 10));//设置数据区 + }) ); service.Start(); Console.WriteLine("服务已启动"); @@ -56,8 +66,13 @@ namespace ModbusSlaveConsoleApp service.Setup(new TouchSocketConfig() //监听端口 .SetBindIPHost(7809) - //设置数据存储区,即线圈、离散输入、保持寄存器、输入寄存器 - .SetModbusDataLocater(new ModbusDataLocater(10, 10, 10, 10)) + .ConfigurePlugins(a => + { + a.AddModbusSlavePoint()//添加一个从站站点 + .SetSlaveId(1)//设置站点号 + .UseIgnoreSlaveId()//忽略站号验证 + .SetModbusDataLocater(new ModbusDataLocater(10, 10, 10, 10));//设置数据区 + }) ); service.Start(); Console.WriteLine("服务已启动"); @@ -70,8 +85,13 @@ namespace ModbusSlaveConsoleApp service.Setup(new TouchSocketConfig() //监听端口 .SetBindIPHost(7811) - //设置数据存储区,即线圈、离散输入、保持寄存器、输入寄存器 - .SetModbusDataLocater(new ModbusDataLocater(10, 10, 10, 10)) + .ConfigurePlugins(a => + { + a.AddModbusSlavePoint()//添加一个从站站点 + .SetSlaveId(1)//设置站点号 + .UseIgnoreSlaveId()//忽略站号验证 + .SetModbusDataLocater(new ModbusDataLocater(10, 10, 10, 10));//设置数据区 + }) ); service.Start(); Console.WriteLine("服务已启动"); @@ -91,8 +111,13 @@ namespace ModbusSlaveConsoleApp PortName = "COM1", StopBits = System.IO.Ports.StopBits.One }) - //设置数据存储区,即线圈、离散输入、保持寄存器、输入寄存器 - .SetModbusDataLocater(new ModbusDataLocater(10, 10, 10, 10)) + .ConfigurePlugins(a => + { + a.AddModbusSlavePoint()//添加一个从站站点 + .SetSlaveId(1)//设置站点号 + //.UseIgnoreSlaveId()//如果不调用,默认会进行站号验证 + .SetModbusDataLocater(new ModbusDataLocater(10, 10, 10, 10));//设置数据区 + }) ); service.Connect(); Console.WriteLine("已连接COM端口"); diff --git a/examples/NAT简单示例/NATServiceConsoleApp/NATServiceConsoleApp.csproj b/examples/NAT简单示例/NATServiceConsoleApp/NATServiceConsoleApp.csproj index dd6c7894f..89f061b8b 100644 --- a/examples/NAT简单示例/NATServiceConsoleApp/NATServiceConsoleApp.csproj +++ b/examples/NAT简单示例/NATServiceConsoleApp/NATServiceConsoleApp.csproj @@ -6,12 +6,12 @@ - - - - - - + + + + + + diff --git a/examples/NamedPipe/NamedPipeClientConsoleApp/NamedPipeClientConsoleApp.csproj b/examples/NamedPipe/NamedPipeClientConsoleApp/NamedPipeClientConsoleApp.csproj index dfd2c8387..55734a101 100644 --- a/examples/NamedPipe/NamedPipeClientConsoleApp/NamedPipeClientConsoleApp.csproj +++ b/examples/NamedPipe/NamedPipeClientConsoleApp/NamedPipeClientConsoleApp.csproj @@ -8,7 +8,7 @@ - + diff --git a/examples/NamedPipe/NamedPipeServiceConsoleApp/NamedPipeServiceConsoleApp.csproj b/examples/NamedPipe/NamedPipeServiceConsoleApp/NamedPipeServiceConsoleApp.csproj index 7eeecec17..a9b5173ca 100644 --- a/examples/NamedPipe/NamedPipeServiceConsoleApp/NamedPipeServiceConsoleApp.csproj +++ b/examples/NamedPipe/NamedPipeServiceConsoleApp/NamedPipeServiceConsoleApp.csproj @@ -8,6 +8,6 @@ - + diff --git a/examples/NamedPipe/NamedPipeStressTestingConsoleApp/NamedPipeStressTestingConsoleApp.csproj b/examples/NamedPipe/NamedPipeStressTestingConsoleApp/NamedPipeStressTestingConsoleApp.csproj index d5a2195ca..26aa67031 100644 --- a/examples/NamedPipe/NamedPipeStressTestingConsoleApp/NamedPipeStressTestingConsoleApp.csproj +++ b/examples/NamedPipe/NamedPipeStressTestingConsoleApp/NamedPipeStressTestingConsoleApp.csproj @@ -8,6 +8,6 @@ - + diff --git a/examples/Rpc/GenerateProxyFromServerConsoleApp/GenerateProxyFromServerConsoleApp.csproj b/examples/Rpc/GenerateProxyFromServerConsoleApp/GenerateProxyFromServerConsoleApp.csproj index 448618afc..e0036d211 100644 --- a/examples/Rpc/GenerateProxyFromServerConsoleApp/GenerateProxyFromServerConsoleApp.csproj +++ b/examples/Rpc/GenerateProxyFromServerConsoleApp/GenerateProxyFromServerConsoleApp.csproj @@ -8,7 +8,7 @@ - + diff --git a/examples/Serial/SerialPortClientConsoleApp/SerialPortClientConsoleApp.csproj b/examples/Serial/SerialPortClientConsoleApp/SerialPortClientConsoleApp.csproj index 941f4e4c7..1a203c7e0 100644 --- a/examples/Serial/SerialPortClientConsoleApp/SerialPortClientConsoleApp.csproj +++ b/examples/Serial/SerialPortClientConsoleApp/SerialPortClientConsoleApp.csproj @@ -8,7 +8,7 @@ - + diff --git a/examples/Tcp/TcpCommandLineConsoleApp/TcpCommandLineConsoleApp.csproj b/examples/Tcp/TcpCommandLineConsoleApp/TcpCommandLineConsoleApp.csproj index a648d707f..925f11709 100644 --- a/examples/Tcp/TcpCommandLineConsoleApp/TcpCommandLineConsoleApp.csproj +++ b/examples/Tcp/TcpCommandLineConsoleApp/TcpCommandLineConsoleApp.csproj @@ -8,12 +8,12 @@ - - - - - - + + + + + + diff --git a/examples/Tcp/TcpConsoleApp/TcpConsoleApp.csproj b/examples/Tcp/TcpConsoleApp/TcpConsoleApp.csproj index 701cbcc20..5d3a54a79 100644 --- a/examples/Tcp/TcpConsoleApp/TcpConsoleApp.csproj +++ b/examples/Tcp/TcpConsoleApp/TcpConsoleApp.csproj @@ -18,8 +18,8 @@ --> - - + + diff --git a/examples/Tcp/TcpServiceForWebApi/TcpServiceForWebApi.csproj b/examples/Tcp/TcpServiceForWebApi/TcpServiceForWebApi.csproj index 9ae9bccd8..39c249f11 100644 --- a/examples/Tcp/TcpServiceForWebApi/TcpServiceForWebApi.csproj +++ b/examples/Tcp/TcpServiceForWebApi/TcpServiceForWebApi.csproj @@ -6,12 +6,12 @@ - - - - - - - + + + + + + + diff --git a/examples/Tcp/TcpWaitingClientWinFormsApp/TcpWaitingClientWinFormsApp.csproj b/examples/Tcp/TcpWaitingClientWinFormsApp/TcpWaitingClientWinFormsApp.csproj index 7412c10c3..f10374ca8 100644 --- a/examples/Tcp/TcpWaitingClientWinFormsApp/TcpWaitingClientWinFormsApp.csproj +++ b/examples/Tcp/TcpWaitingClientWinFormsApp/TcpWaitingClientWinFormsApp.csproj @@ -9,7 +9,7 @@ - + \ No newline at end of file diff --git a/examples/Udp/UdpBroadcastConsoleApp/UdpBroadcastConsoleApp.csproj b/examples/Udp/UdpBroadcastConsoleApp/UdpBroadcastConsoleApp.csproj index a648d707f..925f11709 100644 --- a/examples/Udp/UdpBroadcastConsoleApp/UdpBroadcastConsoleApp.csproj +++ b/examples/Udp/UdpBroadcastConsoleApp/UdpBroadcastConsoleApp.csproj @@ -8,12 +8,12 @@ - - - - - - + + + + + + diff --git a/examples/Udp/UdpDemoApp/UdpDemoApp.csproj b/examples/Udp/UdpDemoApp/UdpDemoApp.csproj index d7fac510f..4c5816908 100644 --- a/examples/Udp/UdpDemoApp/UdpDemoApp.csproj +++ b/examples/Udp/UdpDemoApp/UdpDemoApp.csproj @@ -7,11 +7,11 @@ - - - - - - + + + + + + \ No newline at end of file diff --git a/examples/Udp/UdpScreenCapture/ScreenUdpReceiver/ScreenUdpReceiver.csproj b/examples/Udp/UdpScreenCapture/ScreenUdpReceiver/ScreenUdpReceiver.csproj index cf2b673e2..83a55e062 100644 --- a/examples/Udp/UdpScreenCapture/ScreenUdpReceiver/ScreenUdpReceiver.csproj +++ b/examples/Udp/UdpScreenCapture/ScreenUdpReceiver/ScreenUdpReceiver.csproj @@ -7,7 +7,7 @@ - + \ No newline at end of file diff --git a/examples/Udp/UdpScreenCapture/ScreenUdpSender/ScreenUdpSender.csproj b/examples/Udp/UdpScreenCapture/ScreenUdpSender/ScreenUdpSender.csproj index cf2b673e2..83a55e062 100644 --- a/examples/Udp/UdpScreenCapture/ScreenUdpSender/ScreenUdpSender.csproj +++ b/examples/Udp/UdpScreenCapture/ScreenUdpSender/ScreenUdpSender.csproj @@ -7,7 +7,7 @@ - + \ No newline at end of file diff --git a/examples/Unity3d/UnityServerConsoleApp/UnityServerConsoleApp.csproj b/examples/Unity3d/UnityServerConsoleApp/UnityServerConsoleApp.csproj index 98437e5a7..79cde65e1 100644 --- a/examples/Unity3d/UnityServerConsoleApp/UnityServerConsoleApp.csproj +++ b/examples/Unity3d/UnityServerConsoleApp/UnityServerConsoleApp.csproj @@ -5,6 +5,6 @@ net6.0 - + diff --git a/examples/WebApi/DispatchProxyWebApiConsoleApp/DispatchProxyWebApiConsoleApp.csproj b/examples/WebApi/DispatchProxyWebApiConsoleApp/DispatchProxyWebApiConsoleApp.csproj index af6d46621..67b53a6d9 100644 --- a/examples/WebApi/DispatchProxyWebApiConsoleApp/DispatchProxyWebApiConsoleApp.csproj +++ b/examples/WebApi/DispatchProxyWebApiConsoleApp/DispatchProxyWebApiConsoleApp.csproj @@ -8,6 +8,6 @@ - + diff --git a/examples/WebApi/WebApiClientApp/WebApiClientApp.csproj b/examples/WebApi/WebApiClientApp/WebApiClientApp.csproj index d85d0607d..981a8a432 100644 --- a/examples/WebApi/WebApiClientApp/WebApiClientApp.csproj +++ b/examples/WebApi/WebApiClientApp/WebApiClientApp.csproj @@ -7,6 +7,6 @@ - + \ No newline at end of file diff --git a/examples/WebApi/WebApiServer/WebApiServerApp.csproj b/examples/WebApi/WebApiServer/WebApiServerApp.csproj index 1ab9101af..48a6c92f7 100644 --- a/examples/WebApi/WebApiServer/WebApiServerApp.csproj +++ b/examples/WebApi/WebApiServer/WebApiServerApp.csproj @@ -6,8 +6,8 @@ - - + + diff --git a/examples/WebSocket/AsyncWebSocketConsoleApp/AsyncWebSocketConsoleApp.csproj b/examples/WebSocket/AsyncWebSocketConsoleApp/AsyncWebSocketConsoleApp.csproj index 79d4968a8..3fd238a65 100644 --- a/examples/WebSocket/AsyncWebSocketConsoleApp/AsyncWebSocketConsoleApp.csproj +++ b/examples/WebSocket/AsyncWebSocketConsoleApp/AsyncWebSocketConsoleApp.csproj @@ -7,6 +7,6 @@ enable - + diff --git a/examples/WebSocket/WebSocketConsoleApp/WebSocketConsoleApp.csproj b/examples/WebSocket/WebSocketConsoleApp/WebSocketConsoleApp.csproj index 9f3991253..2d9bf858d 100644 --- a/examples/WebSocket/WebSocketConsoleApp/WebSocketConsoleApp.csproj +++ b/examples/WebSocket/WebSocketConsoleApp/WebSocketConsoleApp.csproj @@ -6,8 +6,8 @@ - - + + diff --git a/examples/XmlRpc/DispatchProxyXmlRpcClientConsoleApp/DispatchProxyXmlRpcClientConsoleApp.csproj b/examples/XmlRpc/DispatchProxyXmlRpcClientConsoleApp/DispatchProxyXmlRpcClientConsoleApp.csproj index b256cc7c3..2eefa9619 100644 --- a/examples/XmlRpc/DispatchProxyXmlRpcClientConsoleApp/DispatchProxyXmlRpcClientConsoleApp.csproj +++ b/examples/XmlRpc/DispatchProxyXmlRpcClientConsoleApp/DispatchProxyXmlRpcClientConsoleApp.csproj @@ -8,6 +8,6 @@ - + diff --git a/examples/XmlRpc/XmlRpcClientApp/XmlRpcClientApp.csproj b/examples/XmlRpc/XmlRpcClientApp/XmlRpcClientApp.csproj index 8e7e9f551..8f647e03c 100644 --- a/examples/XmlRpc/XmlRpcClientApp/XmlRpcClientApp.csproj +++ b/examples/XmlRpc/XmlRpcClientApp/XmlRpcClientApp.csproj @@ -7,6 +7,6 @@ - + \ No newline at end of file diff --git a/examples/XmlRpc/XmlRpcServerApp/XmlRpcServerApp.csproj b/examples/XmlRpc/XmlRpcServerApp/XmlRpcServerApp.csproj index a2a803024..5e0f2e089 100644 --- a/examples/XmlRpc/XmlRpcServerApp/XmlRpcServerApp.csproj +++ b/examples/XmlRpc/XmlRpcServerApp/XmlRpcServerApp.csproj @@ -6,7 +6,7 @@ - + diff --git a/handbook/docs/generichost.mdx b/handbook/docs/generichost.mdx index 19e921458..4ca1e2eb6 100644 --- a/handbook/docs/generichost.mdx +++ b/handbook/docs/generichost.mdx @@ -46,20 +46,6 @@ Hosting通用主机,是在创建一个[HostBuilder](https://learn.microsoft.co ### 3.1 在Aspnetcore中添加 - - - - - - - 但是如果想添加自己的服务,或者想注入同一类型的服务,则需要重新实现。例如:添加自己的TcpService。 首先需要声明一个接口`IMyTcpService`,继承自`ITcpService`,然后声明自定义类`MyTcpService`,继承`TcpService`,同时实现`IMyTcpService`。