public static ClientThread getInstance(Socket clientSocket) throws IOException {
    ObjectOutputStream outputStream = new ObjectOutputStream(clientSocket.getOutputStream());
    outputStream.flush();
    ObjectInputStream inputStream = new ObjectInputStream(clientSocket.getInputStream());
    ClientThread clientThread = new ClientThread(clientSocket, inputStream, outputStream);
    return clientThread;
  }