Instance Method

writeMultipleDatagrams(_:completionHandler:)

Write multiple datagrams

Declaration

func writeMultipleDatagrams(_ datagramArray: [Data], completionHandler: @escaping (Error?) -> Void)

Parameters

datagramArray

An NSArray of NSData objects, containing the ordered list of datagrams to write.

completionHandler

A handler called when the write request has either succeeded or failed.

Discussion

Callers should wait until the completionHandler is executed before issuing another write.

See Also

Transferring Data

var maximumDatagramLength: Int

The maximum size of a datagram to be written currently

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software