Question by fairyprincess: How do you “port program” in Java?
We have a project that requires us to do port programming. I’m really really new at JAVA and I’m wondering if you know any tutorial that will help me in port programming in JAVA.

You can also suggest simple projects that we can do that also requires port programming…

Best answer:

Answer by The Ultimate Answer Guaranteed
This would have you import the sockets class package. Google “java socket class”, the website will have some information on how the classes and methods can be used by you to connect to a port.

Give your answer to this question below!

One thought on “How do you “port program” in Java?”

  1. You mean socket programming (unless you’re specifically writing something to do with the portmapper).

    The first project that springs to mind is a chat program (like ‘instant messaging’).

    As the other person types, the characters appear on a remote machine. It’s good fun to code as you can chat to your friends while testing it out.

    You’ll need to figure out how to create client and server ends of a TCP socket. Search around – you’ll find it in no time.

    You start up a server on your machine, then your friend starts a client on theirs, then you chat!

    If you get that working, add a bit at the start of the client code that does a broadcast (udp) to find out where the servers are without the user having to type them in. Have a dig around and see if you can figure it out. If you can’t, post up specific problems on here and I’ll give you any help I can if I see your questions.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.