Instance Propertyswift-nio 2.74.0NIOWebSocket
description
A String
describing this WebSocketFrame
. Example:
var description: String { get }
Returns
A description of this WebSocketFrame
.
WebSocketFrame {
maskKey: Optional(NIOWebSocket.WebSocketMaskingKey(_key: (187, 28, 185, 79))),
fin: true,
rsv1: true,
rsv2: true,
rsv3: true,
opcode: WebSocketOpcode.binary,
length: 0,
data: ByteBuffer { readerIndex: 0, writerIndex: 0, readableBytes: 0, capacity: 0, storageCapacity: 0, slice: _ByteBufferSlice { 0..<0 }, storage: 0x00006000028246b0 (0 bytes) },
extensionData: nil,
unmaskedData: ByteBuffer { readerIndex: 0, writerIndex: 0, readableBytes: 0, capacity: 0, storageCapacity: 0, slice: _ByteBufferSlice { 0..<0 }, storage: 0x0000600002824800 (0 bytes) },
unmaskedDataExtension: nil
}
The format of the description is not API.
Other members in extension
Type members
init(allocator: ByteBufferAllocator
) Creates an empty
WebSocketFrame
.init(fin: Bool, rsv1: Bool, rsv2: Bool, rsv3: Bool, opcode: WebSocketOpcode, maskKey: WebSocketMaskingKey?, data: ByteBuffer, extensionData: ByteBuffer?
) Create a
WebSocketFrame
with the given properties.
Instance members
var data: ByteBuffer
The application data.
var debugDescription: String
var extensionData: ByteBuffer?
The extension data, if any.
var fin: Bool
The value of the
fin
bit. If set, this is the last frame in a fragmented frame. If not set, this frame is one of the intermediate frames in a fragmented frame. Must be set if a frame is not fragmented at all.var length: Int
The total length of the data in the frame.
var maskKey: WebSocketMaskingKey?
The masking key, if any.
var opcode: WebSocketOpcode
The opcode for this frame.
var rsv1: Bool
The value of the first reserved bit. Must be
false
unless using an extension that defines its use.var rsv2: Bool
The value of the second reserved bit. Must be
false
unless using an extension that defines its use.var rsv3: Bool
The value of the third reserved bit. Must be
false
unless using an extension that defines its use.var unmaskedData: ByteBuffer
The unmasked application data.
var unmaskedExtensionData: ByteBuffer?
The unmasked extension data.