Advertisement
Guest User

Untitled

a guest
Mar 25th, 2017
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.27 KB | None | 0 0
  1. while((line = reader.readLine()) != null){
  2.             if(line.startsWith("PING ")){
  3.                 writer.write("PONG " + line.substring(5) + " \r\n");
  4.                 writer.write("PRIVMSG " + channel + " : I got pinged:\r\n");
  5.                 writer.flush();
  6.             }
  7.             else
  8.                 System.out.println(line);
  9.         }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement