From eb92e6d4212d8ce4acfe122d25aedc5622dad1f8 Mon Sep 17 00:00:00 2001 From: root <295172551@qq.com> Date: Sat, 14 Jun 2025 03:01:12 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8E=BB=E9=99=A4=E5=86=97=E4=BD=99=E6=96=87?= =?UTF-8?q?=E4=BB=B6=20=E5=B7=B2=E7=BB=8F=E4=BF=AE=E6=94=B9=E5=91=BD?= =?UTF-8?q?=E5=90=8D=E7=A9=BA=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../StartCellularNetworkCommand.cs | 2 +- .../Contexts/CellularNetworkContext.cs | 1 - CoreAgent.Domain/CoreAgent.Domain.csproj | 4 +++ .../Network/ICellularNetworkService.cs | 2 +- .../Models/Network/CellularNetworkConfig.cs | 20 -------------- .../Models/Network/CellularNetworkStatus.cs | 27 ------------------- .../Network/CellularNetworkService.cs | 1 - 7 files changed, 6 insertions(+), 51 deletions(-) delete mode 100644 CoreAgent.Domain/Models/Network/CellularNetworkConfig.cs delete mode 100644 CoreAgent.Domain/Models/Network/CellularNetworkStatus.cs diff --git a/CoreAgent.Application/Commands/CellularNetwork/StartCellularNetworkCommand.cs b/CoreAgent.Application/Commands/CellularNetwork/StartCellularNetworkCommand.cs index 6ea2697..4364ba7 100644 --- a/CoreAgent.Application/Commands/CellularNetwork/StartCellularNetworkCommand.cs +++ b/CoreAgent.Application/Commands/CellularNetwork/StartCellularNetworkCommand.cs @@ -1,4 +1,4 @@ -using CoreAgent.Domain.Models.Network; + using MediatR; namespace CoreAgent.Application.Commands.CellularNetwork; diff --git a/CoreAgent.Domain/Contexts/CellularNetworkContext.cs b/CoreAgent.Domain/Contexts/CellularNetworkContext.cs index c9f1c88..80cd9d0 100644 --- a/CoreAgent.Domain/Contexts/CellularNetworkContext.cs +++ b/CoreAgent.Domain/Contexts/CellularNetworkContext.cs @@ -1,5 +1,4 @@ using CoreAgent.Domain.Interfaces.Network; -using CoreAgent.Domain.Models.Network; using CoreAgent.Domain.Models.System; namespace CoreAgent.Domain.Contexts; diff --git a/CoreAgent.Domain/CoreAgent.Domain.csproj b/CoreAgent.Domain/CoreAgent.Domain.csproj index 358f371..0ef5678 100644 --- a/CoreAgent.Domain/CoreAgent.Domain.csproj +++ b/CoreAgent.Domain/CoreAgent.Domain.csproj @@ -11,4 +11,8 @@ + + + + diff --git a/CoreAgent.Domain/Interfaces/Network/ICellularNetworkService.cs b/CoreAgent.Domain/Interfaces/Network/ICellularNetworkService.cs index d077b83..75697f9 100644 --- a/CoreAgent.Domain/Interfaces/Network/ICellularNetworkService.cs +++ b/CoreAgent.Domain/Interfaces/Network/ICellularNetworkService.cs @@ -1,4 +1,4 @@ -using CoreAgent.Domain.Models.Network; + namespace CoreAgent.Domain.Interfaces.Network; diff --git a/CoreAgent.Domain/Models/Network/CellularNetworkConfig.cs b/CoreAgent.Domain/Models/Network/CellularNetworkConfig.cs deleted file mode 100644 index c8f14ce..0000000 --- a/CoreAgent.Domain/Models/Network/CellularNetworkConfig.cs +++ /dev/null @@ -1,20 +0,0 @@ -namespace CoreAgent.Domain.Models.Network; - -/// -/// 蜂窝网络配置 -/// -public class CellularNetworkConfig -{ - /// - /// APN名称 - /// - public string Apn { get; set; } - - /// - /// 频段 - /// - public string[] Band { get; set; } - - - public string Plmn { get; set; } -} \ No newline at end of file diff --git a/CoreAgent.Domain/Models/Network/CellularNetworkStatus.cs b/CoreAgent.Domain/Models/Network/CellularNetworkStatus.cs deleted file mode 100644 index 5b61a5d..0000000 --- a/CoreAgent.Domain/Models/Network/CellularNetworkStatus.cs +++ /dev/null @@ -1,27 +0,0 @@ -namespace CoreAgent.Domain.Models.Network; - -/// -/// 蜂窝网络状态 -/// -public class CellularNetworkStatus -{ - /// - /// 是否启用 - /// - public bool IsEnabled { get; set; } - - /// - /// 连接状态 - /// - public string ConnectionState { get; set; } - - /// - /// 信号强度 - /// - public int SignalStrength { get; set; } - - /// - /// 运营商名称 - /// - public string CarrierName { get; set; } -} \ No newline at end of file diff --git a/CoreAgent.Infrastructure/Services/Network/CellularNetworkService.cs b/CoreAgent.Infrastructure/Services/Network/CellularNetworkService.cs index 5793065..5636a9f 100644 --- a/CoreAgent.Infrastructure/Services/Network/CellularNetworkService.cs +++ b/CoreAgent.Infrastructure/Services/Network/CellularNetworkService.cs @@ -4,7 +4,6 @@ using CoreAgent.Domain.Entities; using CoreAgent.Domain.Interfaces; using CoreAgent.Domain.Interfaces.Network; using CoreAgent.Domain.Interfaces.System.Command; -using CoreAgent.Domain.Models.Network; using CoreAgent.Domain.Models.System; using Microsoft.Extensions.Logging; using Microsoft.Extensions.Options;