Name
NSSocketPortNameServer — Mac OS X 10.0
Synopsis
This subclass of NSPortNameServer accepts and
returns instances of NSSocketPort.
NSConnection objects use port name servers to
register and discover communication ports that can
be used for distributed objects connections. Additional subclasses of
NSPortNameServer that handle other types of ports
are NSMachBootstrapServer and
NSMessagePortNameServer.
Unlike the other port name server classes,
NSSocketPortNameServer can operate over a network.
NSSocketPortNameServer is implemented using the
Foundation framework’s implementation of Rendezvous
found in NSNetService. Clients are able to
discover socket ports by name only.
Note: this class did not function in versions of Mac OS X prior to 10.2.
|
|
@interface NSSocketPortNameServer : NSPortNameServer
|
// Accessor Methods
|
- (void)setDefaultNameServerPortNumber:(unsigned short)portNumber; |
- (unsigned short)defaultNameServerPortNumber;
|
// Class Methods
|
+ (id)sharedInstance;
|
// Instance Methods
|
- (NSPort *)portForName:(NSString *)name; |
- (NSPort *)portForName:(NSString *)name host:(NSString *)host; |
- (NSPort *)portForName:(NSString *)name host:(NSString *)host nameServerPortNumber:(unsigned short)portNumber; |
- (BOOL)registerPort:(NSPort *)port name:(NSString *)name; |
- (BOOL)registerPort:(NSPort *)port name:(NSString *)name nameServerPortNumber:(unsigned short)portNumber ... |
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access