Initializes parameters for DTLS or UDP connections and listeners.


func nw_parameters_create_secure_udp(_ configure_dtls: @escaping nw_parameters_configure_protocol_block_t, _ configure_udp: @escaping nw_parameters_configure_protocol_block_t) -> nw_parameters_t


This function allows you to either use the default configurations for DTLS and UDP, or use customized protocol options. If you want to use the default configuration, pass NW_PARAMETERS_DEFAULT_CONFIGURATION. If you want to customize the options for a protocol, pass a block to modify the options.

If you need to disable DTLS, pass NW_PARAMETERS_DISABLE_PROTOCOL.

See Also

Creating Parameters

typealias nw_parameters_configure_protocol_block_t

A block to configure protocol options during the creation of a parameters object.

func nw_parameters_create() -> nw_parameters_t

Initializes parameters for connections, listeners, and browsers with no protocols specified.

func nw_parameters_create_custom_ip(UInt8, nw_parameters_configure_protocol_block_t) -> nw_parameters_t

Initializes parameters for connections and listeners using a custom IP protocol.

func nw_parameters_copy(nw_parameters_t) -> nw_parameters_t

Peforms a deep copy of a parameters object.