From 20cb77bc4de8ae42c6f42cd617385009eaf1f12b Mon Sep 17 00:00:00 2001
From: dengjunjie <dengjunjie@hnkhzn.com>
Date: 星期二, 28 十月 2025 19:11:54 +0800
Subject: [PATCH] 添加WebSocketServer服务
---
新建文件夹/WIDESEA_WMSServer/WIDESEA_Core/Extensions/WebSocketHostedService.cs | 35 +++++++++++++++++++++++++++++++++++
1 files changed, 35 insertions(+), 0 deletions(-)
diff --git "a/\346\226\260\345\273\272\346\226\207\344\273\266\345\244\271/WIDESEA_WMSServer/WIDESEA_Core/Extensions/WebSocketHostedService.cs" "b/\346\226\260\345\273\272\346\226\207\344\273\266\345\244\271/WIDESEA_WMSServer/WIDESEA_Core/Extensions/WebSocketHostedService.cs"
new file mode 100644
index 0000000..a389508
--- /dev/null
+++ "b/\346\226\260\345\273\272\346\226\207\344\273\266\345\244\271/WIDESEA_WMSServer/WIDESEA_Core/Extensions/WebSocketHostedService.cs"
@@ -0,0 +1,35 @@
+锘縰sing HslCommunication.Core.IMessage;
+using HslCommunication.WebSocket;
+using Microsoft.Extensions.Hosting;
+using Microsoft.Extensions.Logging;
+using Org.BouncyCastle.Asn1.Ocsp;
+using SqlSugar.Extensions;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Text.Json;
+using System.Threading.Tasks;
+
+namespace WIDESEA_Core
+{
+ public class WebSocketHostedService : IHostedService
+ {
+ private readonly WebSocketServer _webSocketServer;
+
+ public WebSocketHostedService(WebSocketServer webSocketServer)
+ {
+ _webSocketServer = webSocketServer;
+ }
+
+ public async Task StartAsync(CancellationToken cancellationToken)
+ {
+ await Task.CompletedTask;
+ }
+
+ public async Task StopAsync(CancellationToken cancellationToken)
+ {
+ await Task.CompletedTask;
+ }
+ }
+}
--
Gitblit v1.9.3