Re: DO and connecting to hostNames
Re: DO and connecting to hostNames
- Subject: Re: DO and connecting to hostNames
- From: Douglas Davidson <email@hidden>
- Date: Mon, 22 Apr 2002 17:12:28 -0700
On Monday, April 22, 2002, at 04:54 PM, Drew Cunningham wrote:
I need to share objects over a network, or even the internet. In the
documentation for NSConnection, it says hostName is an Internet domain
name (for example, "sales.anycorp.com"). How do I go about finding out
what the domain name for a computer is? I would prefer to use IP
addresses make connections to distributed objects but this doesn't
appear to be an option. I want the program to grab an arbitrary port
number, so that I don't have to statically define which port number to
grab (i.e., [[NSSocketPort alloc] init] ). Thanks in advance for any
help / sample code.
NSSocketPort allows you to use an IP address in place of a host name, as
e.g. @"198.68.0.1". However, it does require you to specify a port
number. At present there is no name lookup service available for
NSSocketPort. See some of the posted NSSocketPort examples for more
information.
Douglas Davidson
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.