/* * To change this template, choose Tools | Templates * and open the template in the editor. */ package pm.Server; import eric.GUI.window.tab_main_panel; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.io.PrintWriter; import java.net.ServerSocket; import java.net.Socket; import javax.swing.SwingUtilities; /** * * @author PM */ public class Accept_clients implements Runnable { private ServerSocket ss = null; private Socket socket = null; private int client_nb = 0; private int NB_MAX; private BufferedReader in = null; private String login = null, ip = null; private String clients[][] = null; private ServerControlPanel scp = null; private Communication com = null; private Communication Com[] = null; private PrintWriter out = null; public Accept_clients(ServerControlPanel scp, ServerSocket ss, int NB_MAX, String clients[][]){ this.ss = ss; this.NB_MAX = NB_MAX; this.clients = clients; this.scp = scp; this.Com = new Communication[NB_MAX]; } @Override public void run() { while(client_nb = "+true+"\nEND_MESSAGE"); out.flush(); clients[i][2] = "true"; } } } catch (IOException e) {} } } catch (IOException e) { System.out.println("Erreur d'acceptation Client"); } } } private boolean already_logged(String ip){ for (int i = 0; i