Structure

NWEndpoint.Port

A port number you use along with a host to identify a network endpoint.

Declaration

struct NWEndpoint.Port

Topics

Creating Ports

init?(String)

Initializes a port with a string.

init?(rawValue: UInt16)

Initializes a port with a raw UInt16 value.

init(integerLiteral: NWEndpoint.Port.IntegerLiteralType)

Initializes a port with a literal type.

typealias NWEndpoint.Port.IntegerLiteralType

A literal type defined for ports.

Setting Well-Known Ports

static let any: NWEndpoint.Port

The unspecified port (port 0).

static let ssh: NWEndpoint.Port

The Secure Shell port (port 22).

static let smtp: NWEndpoint.Port

The Simple Mail Transfer Protocol port (port 25).

static let http: NWEndpoint.Port

The Hypertext Transfer Protocol port (port 80).

static let pop: NWEndpoint.Port

The Post Office Protocol port (port 110).

static let imap: NWEndpoint.Port

The Internet Message Access Protocol port (port 143).

static let https: NWEndpoint.Port

The Secure Hypertext Transfer Protocol port (port 443).

static let imaps: NWEndpoint.Port

The Secure Internet Message Access Protocol port (port 993).

static let socks: NWEndpoint.Port

The SOCKS proxy protocol port (port 1080).

See Also

Host and Ports

enum NWEndpoint.Host

A name or address that identifies a network endpoint.