14 Star 54 Fork 31

NtripShare/NtripShareBase

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
SyncRequest.cs 1.29 KB
一键复制 编辑 原始数据 按行查看 历史
NtripShare 提交于 4年前 . 初始版本
using System;
using System.Collections.Generic;
using System.Text;
namespace WatsonTcp
{
/// <summary>
/// Request that demands a response within a specific timeout.
/// </summary>
public class SyncRequest
{
/// <summary>
/// IP:port from which the request was received.
/// </summary>
public string IpPort { get; }
/// <summary>
/// The time at which the request expires.
/// </summary>
public DateTime ExpirationUtc { get; }
/// <summary>
/// Metadata attached to the request.
/// </summary>
public Dictionary<object, object> Metadata { get; }
/// <summary>
/// Request data.
/// </summary>
public byte[] Data { get; }
internal string ConversationGuid { get; }
internal SyncRequest(string ipPort, string convGuid, DateTime expirationUtc, Dictionary<object, object> metadata, byte[] data)
{
IpPort = ipPort;
ConversationGuid = convGuid;
ExpirationUtc = expirationUtc;
Metadata = metadata;
if (data != null)
{
Data = new byte[data.Length];
Buffer.BlockCopy(data, 0, Data, 0, data.Length);
}
}
}
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C#
1
https://gitee.com/ntripshare/ntrip-share-base.git
git@gitee.com:ntripshare/ntrip-share-base.git
ntripshare
ntrip-share-base
NtripShareBase
master

搜索帮助