Contents

NSSocketPortNameServer

A port name server that takes and returns socket ports.

Declaration

@interface NSSocketPortNameServer : NSPortNameServer

Overview

Port removal functionality is supported by the removePortForName: method and should be used to remove invalid socket ports.

Unlike the other port name servers, NSSocketPortNameServer can operate over a network. By registering your socket ports, you make them available to other computers on the local network without hard-coding the TCP port numbers. Clients just need to know the name of the port.

NSPortNameServer is implemented using NetService and registers ports in the local network domain. The registered name of a port must be unique within the local domain, not just the local host. The name server only supports TCP/IP (either IPv4 or IPv6) sockets.

Topics

Getting the Server Object

Looking up Ports

Registering and Removing Ports

Configuring the Default Port Number

See Also

Legacy