XFE Git
XFE Studio Git
Git 首页 全局搜索
XFE 主站 文档 NuGet

XFEToolBox

【WPF】XFE工具箱

公开
关注 0 Fork 0 Star 0
返回提交历史

XFEstudio/XFEToolBox

升级至 net10.0 并新增服务端项目结构

- 将所有项目目标框架升级到 net10.0/net10.0-windows - 升级 XFEExtension.NetCore 及相关依赖包至新版本 - XFEToolBox.sln 增加 XFEToolBox.Server 和 Server.Core 项目,调整结构和依赖 - 新增 XFEToolBox.Server.Core,包含基础类并依赖 XFEToolBox.Core - 新增 XFEToolBox.Server,包含服务端入口及配置、接口示例 - Program.cs 使用 ServerInteractive API 启动服务端 - ServerProfile 和 MainDataProfile 基于 XFEProfile 定义配置 - ToolService 提供示例接口 tool/get/list 便于后续扩展

47084f3
XFE工作室室长 <mail@xfegzs.com>
提交于

代码差异

12 个文件 +122 -19
Modified XFEToolBox.Core/XFEToolBox.Core.csproj +5 -4
@@ -1,15 +1,16 @@
1 1 <Project Sdk="Microsoft.NET.Sdk">
2 2
3 3 <PropertyGroup>
4 <TargetFramework>net8.0</TargetFramework>
4 <TargetFramework>net10.0</TargetFramework>
5 5 <ImplicitUsings>enable</ImplicitUsings>
6 6 <Nullable>enable</Nullable>
7 7 </PropertyGroup>
8 8
9 9 <ItemGroup>
10 <PackageReference Include="XFEExtension.NetCore" Version="3.0.0" />
11 <PackageReference Include="XFEExtension.NetCore.AutoConfig" Version="1.0.4" />
12 <PackageReference Include="XFEExtension.NetCore.AutoPath" Version="1.0.1" />
10 <PackageReference Include="XFEExtension.NetCore" Version="4.2.4" />
11 <PackageReference Include="XFEExtension.NetCore.AutoConfig" Version="3.0.0" />
12 <PackageReference Include="XFEExtension.NetCore.AutoPath" Version="2.0.0" />
13 <PackageReference Include="XFEExtension.NetCore.ServerInteractive" Version="3.2.2" />
13 14 <PackageReference Include="XFEExtension.NetCore.TodoHighLight" Version="1.0.0" />
14 15 </ItemGroup>
15 16
Added XFEToolBox.Server.Core/Class1.cs +6 -0
@@ -0,0 +1,6 @@
1 namespace XFEToolBox.Server.Core;
2
3 public class Class1
4 {
5
6 }
Added XFEToolBox.Server.Core/XFEToolBox.Server.Core.csproj +13 -0
@@ -0,0 +1,13 @@
1 <Project Sdk="Microsoft.NET.Sdk">
2
3 <PropertyGroup>
4 <TargetFramework>net10.0</TargetFramework>
5 <ImplicitUsings>enable</ImplicitUsings>
6 <Nullable>enable</Nullable>
7 </PropertyGroup>
8
9 <ItemGroup>
10 <ProjectReference Include="..\XFEToolBox.Core\XFEToolBox.Core.csproj" />
11 </ItemGroup>
12
13 </Project>
Added XFEToolBox.Server/Profiles/Data/MainDataProfile.cs +8 -0
@@ -0,0 +1,8 @@
1 using XFEExtension.NetCore.AutoConfig;
2
3 namespace XFEToolBox.Server.Profiles.Data;
4
5 public partial class MainDataProfile : XFEProfile
6 {
7
8 }
Added XFEToolBox.Server/Profiles/ServerProfile.cs +12 -0
@@ -0,0 +1,12 @@
1 using XFEExtension.NetCore.AutoConfig;
2
3 namespace XFEToolBox.Server.Profiles;
4
5 public partial class ServerProfile : XFEProfile
6 {
7 [ProfileProperty]
8 private string httpAddress = "http://localhost:3000";
9
10 [ProfileProperty]
11 private string httpsAddress = "https://localhost:3400";
12 }
Added XFEToolBox.Server/Program.cs +19 -0
@@ -0,0 +1,19 @@
1 using XFEExtension.NetCore.ServerInteractive.Interfaces;
2 using XFEExtension.NetCore.ServerInteractive.Utilities.Extensions;
3 using XFEExtension.NetCore.ServerInteractive.Utilities.Server;
4
5 var server = XFEServerBuilder.CreateBuilder()
6 .UseXFEServer()
7 .AddServerCore(XFEServerCoreBuilder.CreateBuilder()
8 .UseXFEStandardServerCore<IUserInfo>(option =>
9 {
10 })
11 .Build(option =>
12 {
13 option.ServerCoreName = "XFEToolBoxServer";
14 option.MainEntryPoint = "api";
15 option.BindIP();
16 }))
17 .Build();
18
19 await server.Start();
Added XFEToolBox.Server/Services/ToolService.cs +13 -0
@@ -0,0 +1,13 @@
1 using XFEExtension.NetCore.ServerInteractive.Attributes;
2 using XFEExtension.NetCore.ServerInteractive.Implements.CoreService;
3
4 namespace XFEToolBox.Server.Services;
5
6 public partial class ToolService : ServerCoreStandardServiceBase
7 {
8 [EntryPoint("tool/get/list")]
9 public async Task GetToolListEntryPoint()
10 {
11
12 }
13 }
Added XFEToolBox.Server/XFEToolBox.Server.csproj +18 -0
@@ -0,0 +1,18 @@
1 <Project Sdk="Microsoft.NET.Sdk">
2
3 <PropertyGroup>
4 <OutputType>Exe</OutputType>
5 <TargetFramework>net10.0</TargetFramework>
6 <ImplicitUsings>enable</ImplicitUsings>
7 <Nullable>enable</Nullable>
8 </PropertyGroup>
9
10 <ItemGroup>
11 <ProjectReference Include="..\XFEToolBox.Server.Core\XFEToolBox.Server.Core.csproj" />
12 </ItemGroup>
13
14 <ItemGroup>
15 <Folder Include="Utilities\" />
16 </ItemGroup>
17
18 </Project>
Modified XFEToolBox.Test/XFEToolBox.Test.csproj +3 -3
@@ -2,15 +2,15 @@
2 2
3 3 <PropertyGroup>
4 4 <OutputType>Exe</OutputType>
5 <TargetFramework>net8.0</TargetFramework>
5 <TargetFramework>net10.0</TargetFramework>
6 6 <ImplicitUsings>enable</ImplicitUsings>
7 7 <Nullable>enable</Nullable>
8 8 </PropertyGroup>
9 9
10 10 <ItemGroup>
11 <PackageReference Include="XFEExtension.NetCore" Version="3.0.0" />
11 <PackageReference Include="XFEExtension.NetCore" Version="4.2.4" />
12 12 <PackageReference Include="XFEExtension.NetCore.TodoHighLight" Version="1.0.0" />
13 <PackageReference Include="XFEExtension.NetCore.XUnit" Version="2.0.3" />
13 <PackageReference Include="XFEExtension.NetCore.XUnit" Version="3.0.0" />
14 14 </ItemGroup>
15 15
16 16 <ItemGroup>
Modified XFEToolBox.sln +19 -6
@@ -1,7 +1,7 @@
1 1 
2 2 Microsoft Visual Studio Solution File, Format Version 12.00
3 # Visual Studio Version 17
4 VisualStudioVersion = 17.11.35017.193
3 # Visual Studio Version 18
4 VisualStudioVersion = 18.8.12009.203 stable
5 5 MinimumVisualStudioVersion = 10.0.40219.1
6 6 Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "XFEToolBox", "XFEToolBox\XFEToolBox.csproj", "{7A065B44-8D37-4415-A97F-9F7C8F8E9567}"
7 7 EndProject
@@ -14,10 +14,14 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "XFEToolBox.Core", "XFEToolB
14 14 EndProject
15 15 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Application", "Application", "{6B2C3055-23D6-4804-928F-F2F0EBE5E6AA}"
16 16 EndProject
17 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Installer", "Installer", "{79A854E4-C4AC-43B3-BBC7-0581CCDB1A1F}"
18 EndProject
19 17 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "XFEToolBoxInstaller", "XFEToolBoxInstaller\XFEToolBoxInstaller.csproj", "{F6F4DC45-737B-47FD-84C5-072C50C64A8E}"
20 18 EndProject
19 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Server", "Server", "{F537CE27-96C2-498B-8CAE-D0EA21A7C425}"
20 EndProject
21 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "XFEToolBox.Server", "XFEToolBox.Server\XFEToolBox.Server.csproj", "{6DCDD456-623E-4DF0-869B-C2F208B623E7}"
22 EndProject
23 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "XFEToolBox.Server.Core", "XFEToolBox.Server.Core\XFEToolBox.Server.Core.csproj", "{6497CE31-AEE5-498F-9EA3-B90A27935DDC}"
24 EndProject
21 25 Global
22 26 GlobalSection(SolutionConfigurationPlatforms) = preSolution
23 27 Debug|Any CPU = Debug|Any CPU
@@ -40,6 +44,14 @@ Global
40 44 {F6F4DC45-737B-47FD-84C5-072C50C64A8E}.Debug|Any CPU.Build.0 = Debug|Any CPU
41 45 {F6F4DC45-737B-47FD-84C5-072C50C64A8E}.Release|Any CPU.ActiveCfg = Release|Any CPU
42 46 {F6F4DC45-737B-47FD-84C5-072C50C64A8E}.Release|Any CPU.Build.0 = Release|Any CPU
47 {6DCDD456-623E-4DF0-869B-C2F208B623E7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
48 {6DCDD456-623E-4DF0-869B-C2F208B623E7}.Debug|Any CPU.Build.0 = Debug|Any CPU
49 {6DCDD456-623E-4DF0-869B-C2F208B623E7}.Release|Any CPU.ActiveCfg = Release|Any CPU
50 {6DCDD456-623E-4DF0-869B-C2F208B623E7}.Release|Any CPU.Build.0 = Release|Any CPU
51 {6497CE31-AEE5-498F-9EA3-B90A27935DDC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
52 {6497CE31-AEE5-498F-9EA3-B90A27935DDC}.Debug|Any CPU.Build.0 = Debug|Any CPU
53 {6497CE31-AEE5-498F-9EA3-B90A27935DDC}.Release|Any CPU.ActiveCfg = Release|Any CPU
54 {6497CE31-AEE5-498F-9EA3-B90A27935DDC}.Release|Any CPU.Build.0 = Release|Any CPU
43 55 EndGlobalSection
44 56 GlobalSection(SolutionProperties) = preSolution
45 57 HideSolutionNode = FALSE
@@ -47,8 +59,9 @@ Global
47 59 GlobalSection(NestedProjects) = preSolution
48 60 {7A065B44-8D37-4415-A97F-9F7C8F8E9567} = {6B2C3055-23D6-4804-928F-F2F0EBE5E6AA}
49 61 {9AEA29D2-6EC5-4CE2-BCC0-850160D81DBF} = {6B2C3055-23D6-4804-928F-F2F0EBE5E6AA}
50 {AA68EC1E-93C8-4D18-8372-64F3D91A66F1} = {6B2C3055-23D6-4804-928F-F2F0EBE5E6AA}
51 {F6F4DC45-737B-47FD-84C5-072C50C64A8E} = {79A854E4-C4AC-43B3-BBC7-0581CCDB1A1F}
62 {F6F4DC45-737B-47FD-84C5-072C50C64A8E} = {6B2C3055-23D6-4804-928F-F2F0EBE5E6AA}
63 {6DCDD456-623E-4DF0-869B-C2F208B623E7} = {F537CE27-96C2-498B-8CAE-D0EA21A7C425}
64 {6497CE31-AEE5-498F-9EA3-B90A27935DDC} = {F537CE27-96C2-498B-8CAE-D0EA21A7C425}
52 65 EndGlobalSection
53 66 GlobalSection(ExtensibilityGlobals) = postSolution
54 67 SolutionGuid = {9EEA9668-487B-420D-A957-97140D8FBCF8}
Modified XFEToolBox/XFEToolBox.csproj +5 -5
@@ -42,13 +42,13 @@
42 42 </ItemGroup>
43 43
44 44 <ItemGroup>
45 <PackageReference Include="CommunityToolkit.Mvvm" Version="8.4.0" />
46 <PackageReference Include="XFEExtension.NetCore" Version="3.3.10" />
47 <PackageReference Include="XFEExtension.NetCore.AutoConfig" Version="2.0.7" />
48 <PackageReference Include="XFEExtension.NetCore.AutoPath" Version="1.0.1" />
45 <PackageReference Include="CommunityToolkit.Mvvm" Version="8.4.2" />
46 <PackageReference Include="XFEExtension.NetCore" Version="4.2.4" />
47 <PackageReference Include="XFEExtension.NetCore.AutoConfig" Version="3.0.0" />
48 <PackageReference Include="XFEExtension.NetCore.AutoPath" Version="2.0.0" />
49 49 <PackageReference Include="XFEExtension.NetCore.InputSimulator" Version="2.3.0" />
50 50 <PackageReference Include="XFEExtension.NetCore.TodoHighLight" Version="1.0.0" />
51 <PackageReference Include="XFEExtension.NetCore.XFEConsole" Version="1.2.3" />
51 <PackageReference Include="XFEExtension.NetCore.XFEConsole" Version="2.2.2" />
52 52 </ItemGroup>
53 53
54 54 <ItemGroup>
Modified XFEToolBoxInstaller/XFEToolBoxInstaller.csproj +1 -1
@@ -2,7 +2,7 @@
2 2
3 3 <PropertyGroup>
4 4 <OutputType>WinExe</OutputType>
5 <TargetFramework>net9.0-windows</TargetFramework>
5 <TargetFramework>net10.0-windows</TargetFramework>
6 6 <Nullable>enable</Nullable>
7 7 <ImplicitUsings>enable</ImplicitUsings>
8 8 <UseWPF>true</UseWPF>