Contents

receive(exactly:)

Receive data from a connection.

Declaration

func receive(exactly: Int) async throws -> ApplicationProtocol.Message<Data>

Parameters

  • exactly:

    Receive exactly this number of bytes from the connection.

Discussion

This may be called before the connection is ready, in which case the receive request will be enqueued until the connection is ready.