From e0fef85b9fb5ba9871c6f7b33bce9311aa1d61dc Mon Sep 17 00:00:00 2001 From: Juster Zhu Date: Wed, 29 Nov 2023 21:53:48 +0800 Subject: [PATCH 1/2] Upgrade the MAUI example to. NET8 --- src/c#/GeneralUpdate.Client/GeneralUpdate.Client.csproj | 5 +---- src/c#/GeneralUpdate.Maui.OSS/GeneralUpdate.Maui.OSS.csproj | 3 +-- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/src/c#/GeneralUpdate.Client/GeneralUpdate.Client.csproj b/src/c#/GeneralUpdate.Client/GeneralUpdate.Client.csproj index 359ffb1..6f527c5 100644 --- a/src/c#/GeneralUpdate.Client/GeneralUpdate.Client.csproj +++ b/src/c#/GeneralUpdate.Client/GeneralUpdate.Client.csproj @@ -1,10 +1,7 @@  - net7.0-android;net7.0-ios;net7.0-maccatalyst - $(TargetFrameworks);net7.0-windows10.0.19041.0 - - + net8.0-android Exe GeneralUpdate.Client true diff --git a/src/c#/GeneralUpdate.Maui.OSS/GeneralUpdate.Maui.OSS.csproj b/src/c#/GeneralUpdate.Maui.OSS/GeneralUpdate.Maui.OSS.csproj index 30dc71e..f150deb 100644 --- a/src/c#/GeneralUpdate.Maui.OSS/GeneralUpdate.Maui.OSS.csproj +++ b/src/c#/GeneralUpdate.Maui.OSS/GeneralUpdate.Maui.OSS.csproj @@ -1,8 +1,7 @@ - net8.0;net8.0-maccatalyst;net8.0-ios;net8.0-android - $(TargetFrameworks);net8.0-windows10.0.22621.0 + net8.0;net8.0-maccatalyst;net8.0-android true -- Gitee From c0a3012b28c7aab7068e0b147a7f0e5b3e9a25e4 Mon Sep 17 00:00:00 2001 From: Juster Zhu Date: Thu, 30 Nov 2023 21:33:07 +0800 Subject: [PATCH 2/2] Add a process information class --- .../MiniBowlBootstrap.cs | 5 ++-- .../Model/ProcessInfo.cs | 27 +++++++++++++++++++ 2 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 src/c#/GeneralUpdate.MiniBowl/Model/ProcessInfo.cs diff --git a/src/c#/GeneralUpdate.MiniBowl/MiniBowlBootstrap.cs b/src/c#/GeneralUpdate.MiniBowl/MiniBowlBootstrap.cs index beac631..5704938 100644 --- a/src/c#/GeneralUpdate.MiniBowl/MiniBowlBootstrap.cs +++ b/src/c#/GeneralUpdate.MiniBowl/MiniBowlBootstrap.cs @@ -1,4 +1,5 @@ -using System; +using GeneralUpdate.MiniBowl.Model; +using System; using System.Collections.Generic; using System.Linq; using System.Text; @@ -8,7 +9,7 @@ namespace GeneralUpdate.MiniBowl { internal class MiniBowlBootstrap { - void WithConfig() { } + void WithConfig(ProcessInfo processInfo) { } void Launch() { } } diff --git a/src/c#/GeneralUpdate.MiniBowl/Model/ProcessInfo.cs b/src/c#/GeneralUpdate.MiniBowl/Model/ProcessInfo.cs new file mode 100644 index 0000000..cee5c43 --- /dev/null +++ b/src/c#/GeneralUpdate.MiniBowl/Model/ProcessInfo.cs @@ -0,0 +1,27 @@ +using System; +using System.Collections.Generic; +using System.Diagnostics; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace GeneralUpdate.MiniBowl.Model +{ + public enum ProcessStatus + { + Run, + None, + Down + } + + internal class ProcessInfo + { + public string Name { get; set; } + + public int Id { get; set; } + + public ProcessStatus Status { get; set; } + + public string Path { get; set; } + } +} -- Gitee