VpnPacketBuffer 类

定义

平台用于管理内存缓冲区。 VpnPacketBuffer 允许以特定顺序发送或接收 IVpnPacketBufferList 对象列表将缓冲区链接在一起。

public ref class VpnPacketBuffer sealed
/// [Windows.Foundation.Metadata.Activatable(Windows.Networking.Vpn.IVpnPacketBufferFactory, 65536, Windows.Foundation.UniversalApiContract)]
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.MTA)]
class VpnPacketBuffer final
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.MTA)]
/// [Windows.Foundation.Metadata.Activatable(Windows.Networking.Vpn.IVpnPacketBufferFactory, 65536, "Windows.Foundation.UniversalApiContract")]
class VpnPacketBuffer final
[Windows.Foundation.Metadata.Activatable(typeof(Windows.Networking.Vpn.IVpnPacketBufferFactory), 65536, typeof(Windows.Foundation.UniversalApiContract))]
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.MTA)]
public sealed class VpnPacketBuffer
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.MTA)]
[Windows.Foundation.Metadata.Activatable(typeof(Windows.Networking.Vpn.IVpnPacketBufferFactory), 65536, "Windows.Foundation.UniversalApiContract")]
public sealed class VpnPacketBuffer
Public NotInheritable Class VpnPacketBuffer
继承
Object Platform::Object IInspectable VpnPacketBuffer
属性

Windows 要求

设备系列
Windows 10 (在 10.0.10240.0 中引入)
API contract
Windows.Foundation.UniversalApiContract (在 v1.0 中引入)
应用功能
networkingVpnProvider

注解

版本历史记录

Windows 版本 SDK 版本 已添加值
1803 17134 TransportContext

构造函数

VpnPacketBuffer(VpnPacketBuffer, UInt32, UInt32)

未使用。

属性

AppId

获取表示导致此数据包流动的应用的应用 ID。 这仅在流的第一个数据包上存在。 此属性的存在表示它是第一个数据包。

Buffer

获取内存缓冲区对象,该对象旨在包含作为 IVpnPacketBufferList的一部分发送或接收的日期数据包。

Status

获取 VpnPacketBuffer的状态。 操作 IVpnPacketBufferList 时,状态属性可用于报告错误。

TransportAffinity

获取或设置一个数字,该数字指定要在 VpnChannel:Start* 方法中指定的传输对象。 这允许在主传输和可选传输之间进行选择。

TransportContext

获取或设置传输上下文对象,例如主机或服务器的名称。

适用于