All:
How can I get the ip&hostname of the host from the LANs?
Of course, the host must be actively!
Thank you ~~
Printable View
All:
How can I get the ip&hostname of the host from the LANs?
Of course, the host must be actively!
Thank you ~~
I don't understand your question. Do you mean TCP/IP hostname? or some Windows naming system?
In general, TCP/IP host name <==> IP mapping is handled by DNS
There is a getHostByName() function in the main Java libraries.
These names are generally static and work whether or not the other computer is up, accepting connections, etc.
Yes, the TCP/IP host name, but how can I get all the host from the LANs
Again, I don't understand what you are asking.
Did you look at the javadocs for getHostByName() ?