diff --git a/api/README_Pipeline.md b/api/README_Pipeline.md
index 570e672..1f7b65c 100644
--- a/api/README_Pipeline.md
+++ b/api/README_Pipeline.md
@@ -84,6 +84,13 @@
| TerminalPhoneNo| string| 设备终端号|
| HexData| string| JT808 Hex String JT808数据包字符串|
+``` 1
+{
+ "TerminalPhoneNo":"123456789012",
+ "HexData":"7E****7E"
+}
+```
+
返回数据:
|属性|数据类型|参数说明|
@@ -155,7 +162,13 @@
|属性|数据类型|参数说明|
|:------:|:------:|:------|
-| terminalPhoneNo| string| 设备终端号|
+| TerminalPhoneNo| string| 设备终端号|
+
+``` 1
+{
+ "TerminalPhoneNo":"123456789012",
+}
+```
返回数据:
@@ -188,7 +201,13 @@
|属性|数据类型|参数说明|
|:------:|:------:|:------|
-| terminalPhoneNo| string| 设备终端号|
+| TerminalPhoneNo| string| 设备终端号|
+
+``` 1
+{
+ "TerminalPhoneNo":"123456789012",
+}
+```
返回数据:
@@ -261,7 +280,13 @@
|属性|数据类型|参数说明|
|:------:|:------:|:------|
-| terminalPhoneNo| string| 设备终端号|
+| TerminalPhoneNo| string| 设备终端号|
+
+``` 1
+{
+ "TerminalPhoneNo":"123456789012",
+}
+```
返回数据:
@@ -294,7 +319,13 @@
|属性|数据类型|参数说明|
|:------:|:------:|:------|
-| terminalPhoneNo| string| 设备终端号|
+| TerminalPhoneNo| string| 设备终端号|
+
+``` 1
+{
+ "TerminalPhoneNo":"123456789012",
+}
+```
返回数据:
@@ -324,7 +355,13 @@
|属性|数据类型|参数说明|
|:------:|:------:|:------|
-| terminalPhoneNo| string| 设备终端号|
+| TerminalPhoneNo| string| 设备终端号|
+
+``` 1
+{
+ "TerminalPhoneNo":"123456789012",
+}
+```
返回数据:
@@ -352,7 +389,13 @@
|属性|数据类型|参数说明|
|:------:|:------:|:------|
-| terminalPhoneNo| string| 设备终端号|
+| TerminalPhoneNo| string| 设备终端号|
+
+``` 1
+{
+ "TerminalPhoneNo":"123456789012",
+}
+```
返回数据:
@@ -370,7 +413,7 @@
}
```
-#### 3.移除sim卡黑名单
+#### 3.获取sim卡黑名单
请求地址:Blacklist/Get
diff --git a/simples/JT808.DotNettySimples.sln b/simples/JT808.DotNettySimples.sln
new file mode 100644
index 0000000..52705a4
--- /dev/null
+++ b/simples/JT808.DotNettySimples.sln
@@ -0,0 +1,51 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31903.59
+MinimumVisualStudioVersion = 10.0.40219.1
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "simples", "simples", "{2459FB59-8A33-49A4-ADBC-A0B12C5886A6}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.DotNetty.SimpleClient", "JT808.DotNetty.SimpleClient\JT808.DotNetty.SimpleClient.csproj", "{E6F61CE8-BFB4-4946-A0D3-AECCE77824E5}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.DotNetty.SimpleServer", "JT808.DotNetty.SimpleServer\JT808.DotNetty.SimpleServer.csproj", "{CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.DotNetty.SimpleQueueServer", "JT808.DotNetty.SimpleQueueServer\JT808.DotNetty.SimpleQueueServer.csproj", "{1DEAC7EA-D662-420B-A1A7-A6E840568F7B}"
+EndProject
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.DotNetty.SimpleQueueService", "JT808.DotNetty.SimpleQueueService\JT808.DotNetty.SimpleQueueService.csproj", "{90E1F1C9-A953-4341-9792-9E2AF4471B68}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Any CPU = Debug|Any CPU
+ Release|Any CPU = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {E6F61CE8-BFB4-4946-A0D3-AECCE77824E5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {E6F61CE8-BFB4-4946-A0D3-AECCE77824E5}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {E6F61CE8-BFB4-4946-A0D3-AECCE77824E5}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {E6F61CE8-BFB4-4946-A0D3-AECCE77824E5}.Release|Any CPU.Build.0 = Release|Any CPU
+ {CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88}.Release|Any CPU.Build.0 = Release|Any CPU
+ {1DEAC7EA-D662-420B-A1A7-A6E840568F7B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {1DEAC7EA-D662-420B-A1A7-A6E840568F7B}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {1DEAC7EA-D662-420B-A1A7-A6E840568F7B}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {1DEAC7EA-D662-420B-A1A7-A6E840568F7B}.Release|Any CPU.Build.0 = Release|Any CPU
+ {90E1F1C9-A953-4341-9792-9E2AF4471B68}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {90E1F1C9-A953-4341-9792-9E2AF4471B68}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {90E1F1C9-A953-4341-9792-9E2AF4471B68}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {90E1F1C9-A953-4341-9792-9E2AF4471B68}.Release|Any CPU.Build.0 = Release|Any CPU
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(NestedProjects) = preSolution
+ {E6F61CE8-BFB4-4946-A0D3-AECCE77824E5} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
+ {CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
+ {1DEAC7EA-D662-420B-A1A7-A6E840568F7B} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
+ {90E1F1C9-A953-4341-9792-9E2AF4471B68} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
+ EndGlobalSection
+ GlobalSection(ExtensibilityGlobals) = postSolution
+ SolutionGuid = {FC0FFCEA-E1EF-4C97-A1C5-F89418B6834B}
+ EndGlobalSection
+EndGlobal
diff --git a/simples/JT808.Gateway.NBIotSimpleClient/JT808.Gateway.NBIotSimpleClient.csproj b/simples/JT808.Gateway.NBIotSimpleClient/JT808.Gateway.NBIotSimpleClient.csproj
index e3bcb61..ceef993 100644
--- a/simples/JT808.Gateway.NBIotSimpleClient/JT808.Gateway.NBIotSimpleClient.csproj
+++ b/simples/JT808.Gateway.NBIotSimpleClient/JT808.Gateway.NBIotSimpleClient.csproj
@@ -2,14 +2,14 @@
Exe
- net5.0
+ net6.0
-
-
-
-
-
+
+
+
+
+
diff --git a/simples/JT808.Gateway.SimpleClient/JT808.Gateway.SimpleClient.csproj b/simples/JT808.Gateway.SimpleClient/JT808.Gateway.SimpleClient.csproj
index 6d5d65d..066aa4e 100644
--- a/simples/JT808.Gateway.SimpleClient/JT808.Gateway.SimpleClient.csproj
+++ b/simples/JT808.Gateway.SimpleClient/JT808.Gateway.SimpleClient.csproj
@@ -2,14 +2,14 @@
Exe
- net5.0
+ net6.0
-
-
-
-
+
+
+
+
diff --git a/simples/JT808.Gateway.SimpleQueueNotification/JT808.Gateway.SimpleQueueNotification.csproj b/simples/JT808.Gateway.SimpleQueueNotification/JT808.Gateway.SimpleQueueNotification.csproj
index b2bcb50..e642c8c 100644
--- a/simples/JT808.Gateway.SimpleQueueNotification/JT808.Gateway.SimpleQueueNotification.csproj
+++ b/simples/JT808.Gateway.SimpleQueueNotification/JT808.Gateway.SimpleQueueNotification.csproj
@@ -1,7 +1,7 @@
- net5.0
+ net6.0
diff --git a/simples/JT808.Gateway.SimpleQueueServer/JT808.Gateway.SimpleQueueServer.csproj b/simples/JT808.Gateway.SimpleQueueServer/JT808.Gateway.SimpleQueueServer.csproj
index f4db71e..6fcb95e 100644
--- a/simples/JT808.Gateway.SimpleQueueServer/JT808.Gateway.SimpleQueueServer.csproj
+++ b/simples/JT808.Gateway.SimpleQueueServer/JT808.Gateway.SimpleQueueServer.csproj
@@ -2,14 +2,14 @@
Exe
- net5.0
+ net6.0
-
-
-
-
+
+
+
+
diff --git a/simples/JT808.Gateway.SimpleQueueService/JT808.Gateway.SimpleQueueService.csproj b/simples/JT808.Gateway.SimpleQueueService/JT808.Gateway.SimpleQueueService.csproj
index 29a3d48..32cf74e 100644
--- a/simples/JT808.Gateway.SimpleQueueService/JT808.Gateway.SimpleQueueService.csproj
+++ b/simples/JT808.Gateway.SimpleQueueService/JT808.Gateway.SimpleQueueService.csproj
@@ -2,14 +2,14 @@
Exe
- net5.0
+ net6.0
-
-
-
-
+
+
+
+
diff --git a/simples/JT808.Gateway.SimpleServer/JT808.Gateway.SimpleServer.csproj b/simples/JT808.Gateway.SimpleServer/JT808.Gateway.SimpleServer.csproj
index cc65e51..e8cf8f8 100644
--- a/simples/JT808.Gateway.SimpleServer/JT808.Gateway.SimpleServer.csproj
+++ b/simples/JT808.Gateway.SimpleServer/JT808.Gateway.SimpleServer.csproj
@@ -2,13 +2,13 @@
Exe
- net5.0
+ net6.0
-
-
-
-
+
+
+
+
diff --git a/simples/JT808.Simples.sln b/simples/JT808.PipelineSimples.sln
similarity index 62%
rename from simples/JT808.Simples.sln
rename to simples/JT808.PipelineSimples.sln
index d2174a1..9cc8ddf 100644
--- a/simples/JT808.Simples.sln
+++ b/simples/JT808.PipelineSimples.sln
@@ -1,14 +1,10 @@
Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio Version 16
-VisualStudioVersion = 16.0.29418.71
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31903.59
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "simples", "simples", "{2459FB59-8A33-49A4-ADBC-A0B12C5886A6}"
EndProject
-Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.DotNetty.SimpleClient", "JT808.DotNetty.SimpleClient\JT808.DotNetty.SimpleClient.csproj", "{E6F61CE8-BFB4-4946-A0D3-AECCE77824E5}"
-EndProject
-Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.DotNetty.SimpleServer", "JT808.DotNetty.SimpleServer\JT808.DotNetty.SimpleServer.csproj", "{CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88}"
-EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.Gateway.SimpleServer", "JT808.Gateway.SimpleServer\JT808.Gateway.SimpleServer.csproj", "{98E1CDD0-4D4E-48FE-968E-260F0CD5F4D3}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.Gateway.SimpleClient", "JT808.Gateway.SimpleClient\JT808.Gateway.SimpleClient.csproj", "{09AFAC3E-4E4D-4B51-962D-BF8489D8BEC6}"
@@ -19,11 +15,7 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.Gateway.SimpleQueueSe
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.Gateway.SimpleQueueNotification", "JT808.Gateway.SimpleQueueNotification\JT808.Gateway.SimpleQueueNotification.csproj", "{163D2EE2-9A62-4E8A-B203-BF147909E89A}"
EndProject
-Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.DotNetty.SimpleQueueServer", "JT808.DotNetty.SimpleQueueServer\JT808.DotNetty.SimpleQueueServer.csproj", "{1DEAC7EA-D662-420B-A1A7-A6E840568F7B}"
-EndProject
-Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.DotNetty.SimpleQueueService", "JT808.DotNetty.SimpleQueueService\JT808.DotNetty.SimpleQueueService.csproj", "{90E1F1C9-A953-4341-9792-9E2AF4471B68}"
-EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "JT808.Gateway.NBIotSimpleClient", "JT808.Gateway.NBIotSimpleClient\JT808.Gateway.NBIotSimpleClient.csproj", "{95F159E4-07A3-4736-9D05-2D88EE43FD5E}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.Gateway.NBIotSimpleClient", "JT808.Gateway.NBIotSimpleClient\JT808.Gateway.NBIotSimpleClient.csproj", "{95F159E4-07A3-4736-9D05-2D88EE43FD5E}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -31,14 +23,6 @@ Global
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
- {E6F61CE8-BFB4-4946-A0D3-AECCE77824E5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {E6F61CE8-BFB4-4946-A0D3-AECCE77824E5}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {E6F61CE8-BFB4-4946-A0D3-AECCE77824E5}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {E6F61CE8-BFB4-4946-A0D3-AECCE77824E5}.Release|Any CPU.Build.0 = Release|Any CPU
- {CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88}.Release|Any CPU.Build.0 = Release|Any CPU
{98E1CDD0-4D4E-48FE-968E-260F0CD5F4D3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{98E1CDD0-4D4E-48FE-968E-260F0CD5F4D3}.Debug|Any CPU.Build.0 = Debug|Any CPU
{98E1CDD0-4D4E-48FE-968E-260F0CD5F4D3}.Release|Any CPU.ActiveCfg = Release|Any CPU
@@ -59,14 +43,6 @@ Global
{163D2EE2-9A62-4E8A-B203-BF147909E89A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{163D2EE2-9A62-4E8A-B203-BF147909E89A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{163D2EE2-9A62-4E8A-B203-BF147909E89A}.Release|Any CPU.Build.0 = Release|Any CPU
- {1DEAC7EA-D662-420B-A1A7-A6E840568F7B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {1DEAC7EA-D662-420B-A1A7-A6E840568F7B}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {1DEAC7EA-D662-420B-A1A7-A6E840568F7B}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {1DEAC7EA-D662-420B-A1A7-A6E840568F7B}.Release|Any CPU.Build.0 = Release|Any CPU
- {90E1F1C9-A953-4341-9792-9E2AF4471B68}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {90E1F1C9-A953-4341-9792-9E2AF4471B68}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {90E1F1C9-A953-4341-9792-9E2AF4471B68}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {90E1F1C9-A953-4341-9792-9E2AF4471B68}.Release|Any CPU.Build.0 = Release|Any CPU
{95F159E4-07A3-4736-9D05-2D88EE43FD5E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{95F159E4-07A3-4736-9D05-2D88EE43FD5E}.Debug|Any CPU.Build.0 = Debug|Any CPU
{95F159E4-07A3-4736-9D05-2D88EE43FD5E}.Release|Any CPU.ActiveCfg = Release|Any CPU
@@ -76,15 +52,11 @@ Global
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
- {E6F61CE8-BFB4-4946-A0D3-AECCE77824E5} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
- {CCE6AEFB-1AB0-4BD9-8EA2-8B4CDD097E88} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
{98E1CDD0-4D4E-48FE-968E-260F0CD5F4D3} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
{09AFAC3E-4E4D-4B51-962D-BF8489D8BEC6} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
{8594AC7F-18B4-439D-B58B-1CEFF0833A1A} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
{E2D1CFEF-417A-4C44-BC2E-E5A160602485} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
{163D2EE2-9A62-4E8A-B203-BF147909E89A} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
- {1DEAC7EA-D662-420B-A1A7-A6E840568F7B} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
- {90E1F1C9-A953-4341-9792-9E2AF4471B68} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
{95F159E4-07A3-4736-9D05-2D88EE43FD5E} = {2459FB59-8A33-49A4-ADBC-A0B12C5886A6}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
diff --git a/simples/build.bat b/simples/build.bat
index b718b37..e159953 100644
--- a/simples/build.bat
+++ b/simples/build.bat
@@ -1,3 +1,4 @@
-dotnet build
+dotnet build JT808.PipelineSimples.sln
+dotnet build JT808.DotNettySimples.sln
pause
\ No newline at end of file
diff --git a/src/JT808.Gateway.Abstractions/Dtos/JT808TerminalPhoneNoDto.cs b/src/JT808.Gateway.Abstractions/Dtos/JT808TerminalPhoneNoDto.cs
new file mode 100644
index 0000000..25b782b
--- /dev/null
+++ b/src/JT808.Gateway.Abstractions/Dtos/JT808TerminalPhoneNoDto.cs
@@ -0,0 +1,14 @@
+using System;
+using System.Collections.Generic;
+using System.Text;
+
+namespace JT808.Gateway.Abstractions.Dtos
+{
+ public class JT808TerminalPhoneNoDto
+ {
+ ///
+ /// 终端手机号
+ ///
+ public string TerminalPhoneNo { get; set; }
+ }
+}
diff --git a/src/JT808.Gateway.Abstractions/JT808.Gateway.Abstractions.csproj b/src/JT808.Gateway.Abstractions/JT808.Gateway.Abstractions.csproj
index 8a804d0..f55f5fa 100644
--- a/src/JT808.Gateway.Abstractions/JT808.Gateway.Abstractions.csproj
+++ b/src/JT808.Gateway.Abstractions/JT808.Gateway.Abstractions.csproj
@@ -1,8 +1,8 @@
- netstandard2.1;net5.0;
- 9.0
+ netstandard2.1;net6.0;
+ 10.0
Copyright 2019.
SmallChi(Koike)
false
@@ -27,12 +27,13 @@
+
-
-
-
-
-
+
+
+
+
+
diff --git a/src/JT808.Gateway.Abstractions/JT808.Gateway.Abstractions.xml b/src/JT808.Gateway.Abstractions/JT808.Gateway.Abstractions.xml
index e43178a..40a83d0 100644
--- a/src/JT808.Gateway.Abstractions/JT808.Gateway.Abstractions.xml
+++ b/src/JT808.Gateway.Abstractions/JT808.Gateway.Abstractions.xml
@@ -85,6 +85,11 @@
远程ip地址
+
+
+ 终端手机号
+
+
最后上线时间
diff --git a/src/JT808.Gateway.Benchmark/JT808.Gateway.CleintBenchmark/JT808.Gateway.CleintBenchmark.csproj b/src/JT808.Gateway.Benchmark/JT808.Gateway.CleintBenchmark/JT808.Gateway.CleintBenchmark.csproj
index d892faf..020fbd0 100644
--- a/src/JT808.Gateway.Benchmark/JT808.Gateway.CleintBenchmark/JT808.Gateway.CleintBenchmark.csproj
+++ b/src/JT808.Gateway.Benchmark/JT808.Gateway.CleintBenchmark/JT808.Gateway.CleintBenchmark.csproj
@@ -2,8 +2,8 @@
Exe
- net5
- 9.0
+ net6
+ 10.0
@@ -16,11 +16,11 @@
-
-
-
-
-
+
+
+
+
+
diff --git a/src/JT808.Gateway.Benchmark/JT808.Gateway.ServerBenchmark/JT808.Gateway.ServerBenchmark.csproj b/src/JT808.Gateway.Benchmark/JT808.Gateway.ServerBenchmark/JT808.Gateway.ServerBenchmark.csproj
index 6fa96fa..251813a 100644
--- a/src/JT808.Gateway.Benchmark/JT808.Gateway.ServerBenchmark/JT808.Gateway.ServerBenchmark.csproj
+++ b/src/JT808.Gateway.Benchmark/JT808.Gateway.ServerBenchmark/JT808.Gateway.ServerBenchmark.csproj
@@ -2,14 +2,14 @@
Exe
- net5
+ net6
-
-
-
-
+
+
+
+
diff --git a/src/JT808.Gateway.Client/JT808.Gateway.Client.csproj b/src/JT808.Gateway.Client/JT808.Gateway.Client.csproj
index 6a981d8..f34cc1f 100644
--- a/src/JT808.Gateway.Client/JT808.Gateway.Client.csproj
+++ b/src/JT808.Gateway.Client/JT808.Gateway.Client.csproj
@@ -2,8 +2,8 @@
- netstandard2.1;net5.0;
- 9.0
+ netstandard2.1;net6.0;
+ 10.0
Copyright 2019.
SmallChi(Koike)
https://github.com/SmallChi/JT808Gateway
@@ -24,10 +24,10 @@
-
-
-
-
+
+
+
+
diff --git a/src/JT808.Gateway.Kafka/JT808.Gateway.Kafka.csproj b/src/JT808.Gateway.Kafka/JT808.Gateway.Kafka.csproj
index ae0d791..cc84117 100644
--- a/src/JT808.Gateway.Kafka/JT808.Gateway.Kafka.csproj
+++ b/src/JT808.Gateway.Kafka/JT808.Gateway.Kafka.csproj
@@ -1,8 +1,8 @@
- netstandard2.1;net5.0;
- 9.0
+ netstandard2.1;net6.0;
+ 10.0
Copyright 2019.
SmallChi(Koike)
https://github.com/SmallChi/JT808Gateway
@@ -21,7 +21,7 @@
$(JT808GatewayPackageVersion)
-
+
diff --git a/src/JT808.Gateway.Services/JT808.Gateway.MsgIdHandler/JT808.Gateway.MsgIdHandler.csproj b/src/JT808.Gateway.Services/JT808.Gateway.MsgIdHandler/JT808.Gateway.MsgIdHandler.csproj
index 5b70171..f0af579 100644
--- a/src/JT808.Gateway.Services/JT808.Gateway.MsgIdHandler/JT808.Gateway.MsgIdHandler.csproj
+++ b/src/JT808.Gateway.Services/JT808.Gateway.MsgIdHandler/JT808.Gateway.MsgIdHandler.csproj
@@ -2,7 +2,7 @@
- netstandard2.1;net5.0;
+ netstandard2.1;net6.0;
9.0
Copyright 2019.
SmallChi(Koike)
diff --git a/src/JT808.Gateway.Services/JT808.Gateway.MsgLogging/JT808.Gateway.MsgLogging.csproj b/src/JT808.Gateway.Services/JT808.Gateway.MsgLogging/JT808.Gateway.MsgLogging.csproj
index e79fd89..1ab7b48 100644
--- a/src/JT808.Gateway.Services/JT808.Gateway.MsgLogging/JT808.Gateway.MsgLogging.csproj
+++ b/src/JT808.Gateway.Services/JT808.Gateway.MsgLogging/JT808.Gateway.MsgLogging.csproj
@@ -2,8 +2,8 @@
- netstandard2.1;net5.0;
- 9.0
+ netstandard2.1;net6.0;
+ 10.0
Copyright 2019.
SmallChi(Koike)
https://github.com/SmallChi/JT808Gateway
diff --git a/src/JT808.Gateway.Services/JT808.Gateway.ReplyMessage/JT808.Gateway.ReplyMessage.csproj b/src/JT808.Gateway.Services/JT808.Gateway.ReplyMessage/JT808.Gateway.ReplyMessage.csproj
index 042684f..ee4a726 100644
--- a/src/JT808.Gateway.Services/JT808.Gateway.ReplyMessage/JT808.Gateway.ReplyMessage.csproj
+++ b/src/JT808.Gateway.Services/JT808.Gateway.ReplyMessage/JT808.Gateway.ReplyMessage.csproj
@@ -1,8 +1,8 @@
- netstandard2.1;net5.0;
- 9.0
+ netstandard2.1;net6.0;
+ 10.0
Copyright 2019.
SmallChi(Koike)
https://github.com/SmallChi/JT808Gateway
diff --git a/src/JT808.Gateway.Services/JT808.Gateway.SessionNotice/JT808.Gateway.SessionNotice.csproj b/src/JT808.Gateway.Services/JT808.Gateway.SessionNotice/JT808.Gateway.SessionNotice.csproj
index 073b165..4a99f51 100644
--- a/src/JT808.Gateway.Services/JT808.Gateway.SessionNotice/JT808.Gateway.SessionNotice.csproj
+++ b/src/JT808.Gateway.Services/JT808.Gateway.SessionNotice/JT808.Gateway.SessionNotice.csproj
@@ -2,8 +2,8 @@
- netstandard2.1;net5.0;
- 9.0
+ netstandard2.1;net6.0;
+ 10.0
Copyright 2019.
SmallChi(Koike)
https://github.com/SmallChi/JT808Gateway
diff --git a/src/JT808.Gateway.Services/JT808.Gateway.Transmit/JT808.Gateway.Transmit.csproj b/src/JT808.Gateway.Services/JT808.Gateway.Transmit/JT808.Gateway.Transmit.csproj
index 963041e..76b32b3 100644
--- a/src/JT808.Gateway.Services/JT808.Gateway.Transmit/JT808.Gateway.Transmit.csproj
+++ b/src/JT808.Gateway.Services/JT808.Gateway.Transmit/JT808.Gateway.Transmit.csproj
@@ -2,8 +2,8 @@
- netstandard2.1;net5.0;
- 9.0
+ netstandard2.1;net6.0;
+ 10.0
Copyright 2019.
SmallChi(Koike)
https://github.com/SmallChi/JT808Gateway
diff --git a/src/JT808.Gateway.Tests/JT808.Gateway.NormalHosting/JT808.Gateway.NormalHosting.csproj b/src/JT808.Gateway.Tests/JT808.Gateway.NormalHosting/JT808.Gateway.NormalHosting.csproj
index 2f51a17..131c6d6 100644
--- a/src/JT808.Gateway.Tests/JT808.Gateway.NormalHosting/JT808.Gateway.NormalHosting.csproj
+++ b/src/JT808.Gateway.Tests/JT808.Gateway.NormalHosting/JT808.Gateway.NormalHosting.csproj
@@ -2,15 +2,15 @@
Exe
- net5
+ net6
-
-
-
-
+
+
+
+
diff --git a/src/JT808.Gateway.Tests/JT808.Gateway.QueueHosting/JT808.Gateway.QueueHosting.csproj b/src/JT808.Gateway.Tests/JT808.Gateway.QueueHosting/JT808.Gateway.QueueHosting.csproj
index f1824b9..0a54e69 100644
--- a/src/JT808.Gateway.Tests/JT808.Gateway.QueueHosting/JT808.Gateway.QueueHosting.csproj
+++ b/src/JT808.Gateway.Tests/JT808.Gateway.QueueHosting/JT808.Gateway.QueueHosting.csproj
@@ -2,7 +2,7 @@
Exe
- net5
+ net6
@@ -10,10 +10,10 @@
-
-
-
-
+
+
+
+
diff --git a/src/JT808.Gateway.Tests/JT808.Gateway.Test/JT808.Gateway.Test.csproj b/src/JT808.Gateway.Tests/JT808.Gateway.Test/JT808.Gateway.Test.csproj
index ba5a5af..b3c618f 100644
--- a/src/JT808.Gateway.Tests/JT808.Gateway.Test/JT808.Gateway.Test.csproj
+++ b/src/JT808.Gateway.Tests/JT808.Gateway.Test/JT808.Gateway.Test.csproj
@@ -1,16 +1,16 @@
- net5.0
+ net6.0
false
-
-
-
-
+
+
+
+
all
diff --git a/src/JT808.Gateway.WebApiClientTool/JT808.Gateway.WebApiClientTool.csproj b/src/JT808.Gateway.WebApiClientTool/JT808.Gateway.WebApiClientTool.csproj
index f17909d..57f866a 100644
--- a/src/JT808.Gateway.WebApiClientTool/JT808.Gateway.WebApiClientTool.csproj
+++ b/src/JT808.Gateway.WebApiClientTool/JT808.Gateway.WebApiClientTool.csproj
@@ -1,7 +1,7 @@
- netstandard2.1;net5.0;
+ netstandard2.1;net6.0;
9.0
Copyright 2019.
SmallChi(Koike)
@@ -25,7 +25,7 @@
-
+
diff --git a/src/JT808.Gateway.WebApiClientTool/JT808.Gateway.WebApiClientTool.xml b/src/JT808.Gateway.WebApiClientTool/JT808.Gateway.WebApiClientTool.xml
index 7c3de3f..4a3ce85 100644
--- a/src/JT808.Gateway.WebApiClientTool/JT808.Gateway.WebApiClientTool.xml
+++ b/src/JT808.Gateway.WebApiClientTool/JT808.Gateway.WebApiClientTool.xml
@@ -24,7 +24,7 @@
统一下发信息
-
+
@@ -33,18 +33,18 @@
-
+
会话服务-通过设备终端号查询对应会话信息
-
+
-
+
会话服务-通过设备终端号移除对应会话
-
+
@@ -53,32 +53,32 @@
-
+
会话服务-通过设备终端号查询对应会话信息
-
+
-
+
会话服务-通过设备终端号移除对应会话
-
+
-
+
SIM卡黑名单服务-将对应SIM号加入黑名单
-
+
-
+
SIM卡黑名单服务-将对应SIM号移除黑名单
-
+
diff --git a/src/JT808.Gateway.WebApiClientTool/JT808HttpClient.cs b/src/JT808.Gateway.WebApiClientTool/JT808HttpClient.cs
index 4847109..ad361dc 100644
--- a/src/JT808.Gateway.WebApiClientTool/JT808HttpClient.cs
+++ b/src/JT808.Gateway.WebApiClientTool/JT808HttpClient.cs
@@ -32,12 +32,12 @@ namespace JT808.Gateway.WebApiClientTool
///
/// 统一下发信息
///
- ///
+ ///
///
- public async ValueTask> UnificationSend(JT808UnificationSendRequestDto jT808UnificationSendRequestDto)
+ public async ValueTask> UnificationSend(JT808UnificationSendRequestDto parameter)
{
var request = new HttpRequestMessage(HttpMethod.Post, JT808GatewayConstants.JT808WebApiRouteTable.UnificationSend);
- request.Content = new StringContent(JsonSerializer.Serialize(jT808UnificationSendRequestDto));
+ request.Content = new StringContent(JsonSerializer.Serialize(parameter));
var response = await HttpClient.SendAsync(request);
response.EnsureSuccessStatusCode();
var data = await response.Content.ReadAsStreamAsync();
@@ -62,12 +62,12 @@ namespace JT808.Gateway.WebApiClientTool
///
/// 会话服务-通过设备终端号查询对应会话信息
///
- ///
+ ///
///
- public async ValueTask> QueryTcpSessionByTerminalPhoneNo(string terminalPhoneNo)
+ public async ValueTask> QueryTcpSessionByTerminalPhoneNo(JT808TerminalPhoneNoDto parameter)
{
var request = new HttpRequestMessage(HttpMethod.Post, JT808GatewayConstants.JT808WebApiRouteTable.QueryTcpSessionByTerminalPhoneNo);
- request.Content = new StringContent(terminalPhoneNo);
+ request.Content = new StringContent(JsonSerializer.Serialize(parameter));
var response = await HttpClient.SendAsync(request);
response.EnsureSuccessStatusCode();
var data = await response.Content.ReadAsStreamAsync();
@@ -78,12 +78,12 @@ namespace JT808.Gateway.WebApiClientTool
///
/// 会话服务-通过设备终端号移除对应会话
///
- ///
+ ///
///
- public async ValueTask> RemoveTcpByTerminalPhoneNo(string terminalPhoneNo)
+ public async ValueTask> RemoveTcpByTerminalPhoneNo(JT808TerminalPhoneNoDto parameter)
{
var request = new HttpRequestMessage(HttpMethod.Post, JT808GatewayConstants.JT808WebApiRouteTable.SessionRemoveByTerminalPhoneNo);
- request.Content = new StringContent(terminalPhoneNo);
+ request.Content = new StringContent(JsonSerializer.Serialize(parameter));
var response = await HttpClient.SendAsync(request);
response.EnsureSuccessStatusCode();
var data = await response.Content.ReadAsStreamAsync();
@@ -108,12 +108,12 @@ namespace JT808.Gateway.WebApiClientTool
///
/// 会话服务-通过设备终端号查询对应会话信息
///
- ///
+ ///
///
- public async ValueTask> QueryUdpSessionByTerminalPhoneNo(string terminalPhoneNo)
+ public async ValueTask> QueryUdpSessionByTerminalPhoneNo(JT808TerminalPhoneNoDto parameter)
{
var request = new HttpRequestMessage(HttpMethod.Post, JT808GatewayConstants.JT808WebApiRouteTable.QueryUdpSessionByTerminalPhoneNo);
- request.Content = new StringContent(terminalPhoneNo);
+ request.Content = new StringContent(JsonSerializer.Serialize(parameter));
var response = await HttpClient.SendAsync(request);
response.EnsureSuccessStatusCode();
var data = await response.Content.ReadAsStreamAsync();
@@ -124,12 +124,12 @@ namespace JT808.Gateway.WebApiClientTool
///
/// 会话服务-通过设备终端号移除对应会话
///
- ///
+ ///
///
- public async ValueTask> RemoveUdpByTerminalPhoneNo(string terminalPhoneNo)
+ public async ValueTask> RemoveUdpByTerminalPhoneNo(JT808TerminalPhoneNoDto parameter)
{
var request = new HttpRequestMessage(HttpMethod.Post, JT808GatewayConstants.JT808WebApiRouteTable.RemoveUdpByTerminalPhoneNo);
- request.Content = new StringContent(terminalPhoneNo);
+ request.Content = new StringContent(JsonSerializer.Serialize(parameter));
var response = await HttpClient.SendAsync(request);
response.EnsureSuccessStatusCode();
var data = await response.Content.ReadAsStreamAsync();
@@ -140,12 +140,12 @@ namespace JT808.Gateway.WebApiClientTool
///
/// SIM卡黑名单服务-将对应SIM号加入黑名单
///
- ///
+ ///
///
- public async ValueTask> BlacklistAdd(string terminalPhoneNo)
+ public async ValueTask> BlacklistAdd(JT808TerminalPhoneNoDto parameter)
{
var request = new HttpRequestMessage(HttpMethod.Post, JT808GatewayConstants.JT808WebApiRouteTable.BlacklistAdd);
- request.Content = new StringContent(terminalPhoneNo);
+ request.Content = new StringContent(JsonSerializer.Serialize(parameter));
var response = await HttpClient.SendAsync(request);
response.EnsureSuccessStatusCode();
var data = await response.Content.ReadAsStreamAsync();
@@ -156,12 +156,12 @@ namespace JT808.Gateway.WebApiClientTool
///
/// SIM卡黑名单服务-将对应SIM号移除黑名单
///
- ///
+ ///
///
- public async ValueTask> BlacklistRemove(string terminalPhoneNo)
+ public async ValueTask> BlacklistRemove(JT808TerminalPhoneNoDto parameter)
{
var request = new HttpRequestMessage(HttpMethod.Post, JT808GatewayConstants.JT808WebApiRouteTable.BlacklistRemove);
- request.Content = new StringContent(terminalPhoneNo);
+ request.Content = new StringContent(JsonSerializer.Serialize(parameter));
var response = await HttpClient.SendAsync(request);
response.EnsureSuccessStatusCode();
var data = await response.Content.ReadAsStreamAsync();
diff --git a/src/JT808.Gateway.sln b/src/JT808.Gateway.sln
index 64ce825..712022c 100644
--- a/src/JT808.Gateway.sln
+++ b/src/JT808.Gateway.sln
@@ -1,7 +1,7 @@
Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio Version 16
-VisualStudioVersion = 16.0.29409.12
+# Visual Studio Version 17
+VisualStudioVersion = 17.0.31903.59
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.Gateway", "JT808.Gateway\JT808.Gateway.csproj", "{4C8A2546-8333-416D-B123-91062B630087}"
EndProject
@@ -39,6 +39,11 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.Gateway.CleintBenchma
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "JT808.Gateway.MsgIdHandler", "JT808.Gateway.Services\JT808.Gateway.MsgIdHandler\JT808.Gateway.MsgIdHandler.csproj", "{41E5252C-CA52-453A-BBFE-CBCB58D232ED}"
EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{2336747A-28A3-443E-8E23-4B25E3F2D971}"
+ ProjectSection(SolutionItems) = preProject
+ Version.props = Version.props
+ EndProjectSection
+EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
diff --git a/src/JT808.Gateway/Handlers/JT808MsgIdDefaultWebApiHandler.cs b/src/JT808.Gateway/Handlers/JT808MsgIdDefaultWebApiHandler.cs
index 969bf7a..f99c9dd 100644
--- a/src/JT808.Gateway/Handlers/JT808MsgIdDefaultWebApiHandler.cs
+++ b/src/JT808.Gateway/Handlers/JT808MsgIdDefaultWebApiHandler.cs
@@ -73,10 +73,12 @@ namespace JT808.Gateway.Handlers
{
return EmptyHttpResponse();
}
+
JT808ResultDto resultDto = new JT808ResultDto();
try
{
- resultDto.Data = SessionManager.GetTcpAll().Where(w => w.TerminalPhoneNo == json).Select(s => new JT808TcpSessionInfoDto
+ JT808TerminalPhoneNoDto parameter = JsonSerializer.Deserialize(json);
+ resultDto.Data = SessionManager.GetTcpAll(w => w.TerminalPhoneNo == parameter.TerminalPhoneNo).Select(s => new JT808TcpSessionInfoDto
{
LastActiveTime = s.ActiveTime,
StartTime = s.StartTime,
@@ -108,7 +110,8 @@ namespace JT808.Gateway.Handlers
JT808ResultDto resultDto = new JT808ResultDto();
try
{
- SessionManager.RemoveByTerminalPhoneNo(json);
+ JT808TerminalPhoneNoDto parameter = JsonSerializer.Deserialize(json);
+ SessionManager.RemoveByTerminalPhoneNo(parameter.TerminalPhoneNo);
resultDto.Code = JT808ResultCode.Ok;
resultDto.Data = true;
}
@@ -169,7 +172,8 @@ namespace JT808.Gateway.Handlers
JT808ResultDto resultDto = new JT808ResultDto();
try
{
- resultDto.Data = SessionManager.GetUdpAll().Where(w => w.TerminalPhoneNo == json).Select(s => new JT808UdpSessionInfoDto
+ JT808TerminalPhoneNoDto parameter = JsonSerializer.Deserialize(json);
+ resultDto.Data = SessionManager.GetUdpAll(w => w.TerminalPhoneNo == parameter.TerminalPhoneNo).Select(s => new JT808UdpSessionInfoDto
{
LastActiveTime = s.ActiveTime,
StartTime = s.StartTime,
@@ -201,7 +205,8 @@ namespace JT808.Gateway.Handlers
JT808ResultDto resultDto = new JT808ResultDto();
try
{
- SessionManager.RemoveByTerminalPhoneNo(json);
+ JT808TerminalPhoneNoDto parameter = JsonSerializer.Deserialize(json);
+ SessionManager.RemoveByTerminalPhoneNo(parameter.TerminalPhoneNo);
resultDto.Code = JT808ResultCode.Ok;
resultDto.Data = true;
}
@@ -263,7 +268,8 @@ namespace JT808.Gateway.Handlers
JT808ResultDto resultDto = new JT808ResultDto();
try
{
- BlacklistManager.Add(json);
+ JT808TerminalPhoneNoDto parameter = JsonSerializer.Deserialize(json);
+ BlacklistManager.Add(parameter.TerminalPhoneNo);
resultDto.Data = true;
resultDto.Code = JT808ResultCode.Ok;
}
@@ -290,7 +296,8 @@ namespace JT808.Gateway.Handlers
JT808ResultDto resultDto = new JT808ResultDto();
try
{
- BlacklistManager.Remove(json);
+ JT808TerminalPhoneNoDto parameter = JsonSerializer.Deserialize(json);
+ BlacklistManager.Remove(parameter.TerminalPhoneNo);
resultDto.Data = true;
resultDto.Code = JT808ResultCode.Ok;
}
@@ -304,7 +311,7 @@ namespace JT808.Gateway.Handlers
}
///
- /// 移除sim卡黑名单
+ /// 查询sim卡黑名单
///
///
///
diff --git a/src/JT808.Gateway/JT808.Gateway.csproj b/src/JT808.Gateway/JT808.Gateway.csproj
index a10e310..203e679 100644
--- a/src/JT808.Gateway/JT808.Gateway.csproj
+++ b/src/JT808.Gateway/JT808.Gateway.csproj
@@ -1,8 +1,8 @@
- netstandard2.1;net5.0;
- 8.0
+ netstandard2.1;net6.0;
+ 10.0
Copyright 2019.
SmallChi(Koike)
false
@@ -25,11 +25,11 @@
-
-
-
-
+
+
+
+
diff --git a/src/JT808.Gateway/JT808.Gateway.xml b/src/JT808.Gateway/JT808.Gateway.xml
index 9301a55..b15b7aa 100644
--- a/src/JT808.Gateway/JT808.Gateway.xml
+++ b/src/JT808.Gateway/JT808.Gateway.xml
@@ -81,7 +81,7 @@
- 移除sim卡黑名单
+ 查询sim卡黑名单
diff --git a/src/JT808.Gateway/JT808HttpServer.cs b/src/JT808.Gateway/JT808HttpServer.cs
index c370751..12cd6a7 100644
--- a/src/JT808.Gateway/JT808HttpServer.cs
+++ b/src/JT808.Gateway/JT808HttpServer.cs
@@ -64,7 +64,7 @@ namespace JT808.Gateway
Logger.LogWarning(ex, $"{ex.Message}:使用cmd命令[netsh http add urlacl url=http://*:{Configuration.WebApiPort}/ user=Everyone]");
}
Logger.LogInformation($"JT808 Http Server start at {IPAddress.Any}:{Configuration.WebApiPort}.");
- Task.Factory.StartNew(async () =>
+ Task.Run(async () =>
{
while (listener.IsListening)
{
diff --git a/src/JT808.Gateway/JT808TcpServer.cs b/src/JT808.Gateway/JT808TcpServer.cs
index 93972e4..4f730ce 100644
--- a/src/JT808.Gateway/JT808TcpServer.cs
+++ b/src/JT808.Gateway/JT808TcpServer.cs
@@ -95,7 +95,7 @@ namespace JT808.Gateway
public Task StartAsync(CancellationToken cancellationToken)
{
Logger.LogInformation($"JT808 TCP Server start at {IPAddress.Any}:{ConfigurationMonitor.CurrentValue.TcpPort}.");
- Task.Factory.StartNew(async () =>
+ Task.Run(async () =>
{
while (!cancellationToken.IsCancellationRequested)
{
diff --git a/src/JT808.Gateway/JT808UdpServer.cs b/src/JT808.Gateway/JT808UdpServer.cs
index 3f34a7d..62d4f5d 100644
--- a/src/JT808.Gateway/JT808UdpServer.cs
+++ b/src/JT808.Gateway/JT808UdpServer.cs
@@ -80,12 +80,10 @@ namespace JT808.Gateway
{
Logger.LogError(ex, "Receive MessageFrom Async");
}
-#pragma warning disable CA1031 // Do not catch general exception types
catch (Exception ex)
{
Logger.LogError(ex, $"Received Bytes");
}
-#pragma warning restore CA1031 // Do not catch general exception types
finally
{
ArrayPool.Shared.Return(buffer);
diff --git a/src/JT808.Gateway/Session/JT808SessionManager.cs b/src/JT808.Gateway/Session/JT808SessionManager.cs
index 40438f0..532df42 100644
--- a/src/JT808.Gateway/Session/JT808SessionManager.cs
+++ b/src/JT808.Gateway/Session/JT808SessionManager.cs
@@ -261,14 +261,24 @@ namespace JT808.Gateway.Session
}
}
- public List GetTcpAll()
+ public List GetTcpAll(Func predicate=null)
{
- return TerminalPhoneNoSessions.Where(w => w.Value.TransportProtocolType == JT808TransportProtocolType.tcp).Select(s => (JT808TcpSession)s.Value).ToList();
+ var query = TerminalPhoneNoSessions.Where(w => w.Value.TransportProtocolType == JT808TransportProtocolType.tcp);
+ if (predicate != null)
+ {
+ query = query.Where(s => predicate(s.Value));
+ }
+ return query.Select(s => (JT808TcpSession)s.Value).ToList();
}
- public List GetUdpAll()
+ public List GetUdpAll(Func predicate = null)
{
- return TerminalPhoneNoSessions.Where(w => w.Value.TransportProtocolType == JT808TransportProtocolType.udp).Select(s => (JT808UdpSession)s.Value).ToList();
+ var query = TerminalPhoneNoSessions.Where(w => w.Value.TransportProtocolType == JT808TransportProtocolType.udp);
+ if (predicate != null)
+ {
+ query = query.Where(s => predicate(s.Value));
+ }
+ return query.Select(s => (JT808UdpSession)s.Value).ToList();
}
}
}
diff --git a/src/Version.props b/src/Version.props
index 15b1e09..847da20 100644
--- a/src/Version.props
+++ b/src/Version.props
@@ -1,6 +1,6 @@
2.3.6
- 1.1.4
+ 1.1.5-preview1
\ No newline at end of file