MessagePackFragment 结构

定义

使用 MessagePack 序列化的字节序列。

[MessagePack.MessagePackFormatter(typeof(Microsoft.VisualStudio.RpcContracts.RemoteUI.MessagePackFragment+MessagePackFragmentFormatter))]
[Newtonsoft.Json.JsonConverter(typeof(Microsoft.VisualStudio.RpcContracts.RemoteUI.MessagePackFragment+MessagePackFragmentConverter))]
[System.Runtime.CompilerServices.IsReadOnly]
public readonly struct MessagePackFragment
[<MessagePack.MessagePackFormatter(typeof(Microsoft.VisualStudio.RpcContracts.RemoteUI.MessagePackFragment+MessagePackFragmentFormatter))>]
[<Newtonsoft.Json.JsonConverter(typeof(Microsoft.VisualStudio.RpcContracts.RemoteUI.MessagePackFragment+MessagePackFragmentConverter))>]
[<System.Runtime.CompilerServices.IsReadOnly>]
type MessagePackFragment = struct
Public Structure MessagePackFragment
继承
MessagePackFragment
属性
MessagePack.MessagePackFormatterAttribute Newtonsoft.Json.JsonConverterAttribute IsReadOnlyAttribute

注解

MessagePackFragment当 序列化为较大 MessagePack 有效负载的一部分时,会将其写入为原始数据,并带有其长度前缀。 这允许将较大的有效负载记录为 json,以可读格式显示片段的内容。 反序列化后,将按原样检索片段,以便将其与包含它的有效负载分开进行反序列化,可能在以后进行反序列化。

构造函数

MessagePackFragment(ReadOnlySequence<Byte>)

初始化 MessagePackFragment 结构的新实例。

属性

Data

获取 MessagePack 格式的字节序列。

Length

获取片段的长度(以字节为单位)。

适用于