• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: HowTo get computer name from IP
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: HowTo get computer name from IP


  • Subject: Re: HowTo get computer name from IP
  • From: Jeff Harrell <email@hidden>
  • Date: Wed, 18 Jun 2003 00:03:11 -0500

Why don't use you the name attribute of the NSNetService instance?

One of the assumptions about Rendezvous is that it shouldn't matter to the user where a service is located; things like the IP address (and, by extension, hostname) and the port number are abstracted away. The name property is intended to be a human-readable identifier.

I don't know anything about what you're doing, but in the absence of any other information [foo name] (for some NSNetService instance foo) is probably what you ought to use.

On Tuesday, June 17, 2003, at 11:34 PM, Lloyd Dupont wrote:

I get an IP address (from NSNetServiceBrowswer) of a remote computer.
I try to get a friendly name to display to the user.

I'm using NSHost for that, and didn't deliver me any name !
although I do my test on localhost !

I don't understand, if I 'ping ihookIT.local', (the rendezvous name) it work, even from a remote computer. why NSHost hasn't a clue ?
Anyway could you suggest me an other way to get a host name from an IP ?
_______________________________________________
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.



--
email@hidden
http://homepage.mac.com/jharrell
_______________________________________________
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.

  • Follow-Ups:
    • Re: HowTo get computer name from IP
      • From: Lloyd Dupont <email@hidden>
  • Prev by Date: HowTo get computer name from IP
  • Next by Date: Re: HowTo get computer name from IP
  • Previous by thread: Re: HowTo get computer name from IP
  • Next by thread: Re: HowTo get computer name from IP
  • Index(es):
    • Date
    • Thread