Win a copy of Java 9 Revealed this week in the Features new in Java 9 forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

client code and server code question  RSS feed

 
fei lin
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
as I understand it correctly, client code and server code is packaged and deployed together(runme.jar) but when it comes to running the client, it only uses client classes, and when it comes to starting server, it also only run server code. am I right? identical code in client and server?

Thanks in advance
 
Javier Corral
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes,

I have created a class which just receives a parameter indicating wheter the user wants to run the client alone, the client on network or the server. Then this class runs the server class or the client class depending on this argument.

I hope it helps you.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!