Static Methodasync-http-client 1.25.2AsyncHTTPClient
bytes(_:)
HTTPClientResponse.swift:216- iOS
- 13.0+
- macOS
- 10.15+
- tvOS
- 13.0+
- watchOS
- 6.0+
static func bytes(_ byteBuffer: ByteBuffer) -> HTTPClientResponse.Body
static func bytes(_ byteBuffer: ByteBuffer) -> HTTPClientResponse.Body
s15AsyncHTTPClient0B8ResponseV4BodyV5bytesyAE7NIOCore10ByteBufferVFZ
What are these?8ULDE
import AsyncHTTPClient
This package provides simple HTTP Client library built on top of SwiftNIO.
struct Body
A representation of the response body for an HTTP response.
struct HTTPClientResponse
A representation of an HTTP response for the Swift Concurrency HTTPClient API.
struct ByteBuffer
ByteBuffer
stores contiguously allocated raw bytes. It is a random and sequential accessible sequence of zero or more bytes (octets).
init()
static func stream<SequenceOfBytes>(_ sequenceOfBytes: SequenceOfBytes) -> HTTPClientResponse.Body where SequenceOfBytes : Sendable, SequenceOfBytes : AsyncSequence, SequenceOfBytes.Element == ByteBuffer
func collect(upTo maxBytes: Int) async throws -> ByteBuffer
Accumulates Body
of ByteBuffer
s into a single ByteBuffer
.
func makeAsyncIterator() -> AsyncIterator
struct AsyncIterator
typealias Element = ByteBuffer