.jar file command shell - server client program [closed]

-2

I developed a program of the client server type, in which I have two mains:

  • one to run the server
  • other to run multiple clients

To extract the .jar file from ecplise I make export runnable Jar File.

Can I run the command console when I have only one main and two mains? Is that when I export I have to clarify main to run the program.

It does not make sense to join the two mains since I only need to run the server once. Yes, I need to run the client several times

    
asked by anonymous 12.12.2016 / 22:40

1 answer

1

Basically when there is a program of the client-server genre the solution in creating a runnable jar with two mains is to separate and create two separate jar's. One jar with the server, and another jar with the client. This way it is possible to launch the server and several clients connected to that server because they connect themselves to the same server socket.

    
30.12.2016 / 18:40