Type Alias
MultipartPartBodyElement
The requirements a type must meet to be used as the body of a
MultipartPart.typealias MultipartPartBodyElement = RangeReplaceableCollection<UInt8> & Sendable
Discussion
Any collection of bytes which can be built up incrementally qualifies, which includes [UInt8], ArraySlice<UInt8>, and SwiftNIO’s ByteBufferView, among others. Parsers and writers are generic over this type, so a message can be parsed into, or serialized out of, whichever byte container best suits the surrounding code.