Browse Source

添加消息体

tags/v1.3.0
SmallChi 7 years ago
parent
commit
fd7712a84f
4 changed files with 35 additions and 1 deletions
  1. +5
    -0
      src/JT809.Protocol/JT809.Protocol.csproj
  2. +14
    -0
      src/JT809.Protocol/ProtocolPacket/Message/MainLink/MainLink_Login.cs
  3. +14
    -0
      src/JT809.Protocol/ProtocolPacket/MessageBody.cs
  4. +2
    -1
      src/JT809.Protocol/ProtocolPacket/Package.cs

+ 5
- 0
src/JT809.Protocol/JT809.Protocol.csproj View File

@@ -4,8 +4,13 @@
<TargetFramework>netstandard2.0</TargetFramework>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<DocumentationFile>bin\Release\netstandard2.0\JT809.Protocol.xml</DocumentationFile>
</PropertyGroup>
<ItemGroup>
<Folder Include="Encrypt\" />
<Folder Include="ProtocolPacket\Message\SlaveLink\" />
</ItemGroup>
</Project>

+ 14
- 0
src/JT809.Protocol/ProtocolPacket/Message/MainLink/MainLink_Login.cs View File

@@ -0,0 +1,14 @@
using System;
using System.Collections.Generic;
using System.Text;

namespace JT809.Protocol.ProtocolPacket.Message.MainLink
{
/// <summary>
/// 主链路登录请求消息
/// </summary>
public sealed class MainLink_Login: MessageBody
{

}
}

+ 14
- 0
src/JT809.Protocol/ProtocolPacket/MessageBody.cs View File

@@ -0,0 +1,14 @@
using System;
using System.Collections.Generic;
using System.Text;

namespace JT809.Protocol.ProtocolPacket
{
/// <summary>
/// 抽象消息体
/// </summary>
public abstract class MessageBody
{
public IEncrypt Encrypt { get; set; }
}
}

+ 2
- 1
src/JT809.Protocol/ProtocolPacket/Package.cs View File

@@ -13,7 +13,8 @@ namespace JT809.Protocol.ProtocolPacket
public const int CrcByteLength = 2;
public const byte BeginFlag = 0X5B;
public const byte EndFlag = 0X5D;
public Header Header { get; private set; }
public Header Header { get; set; }
public MessageBody MessageBody { get; set; }
private ushort CRCCheckCode { get; set; }
}
}

Loading…
Cancel
Save