public static void sendInfo(SocketChannel sc, Event e) throws IOException { NetUtil.writeLine(sc, "INFO " + e.getType().name() + " " + e.getX() + " " + e.getY()); }
public static void remove(SocketChannel sc, Event e) throws IOException { NetUtil.writeLine(sc, "REMOVE " + e.getType().name() + " " + e.getX() + " " + e.getY()); }
public static void sendInfos(SocketChannel sc, ArrayList<Event> list) throws IOException { NetUtil.writeLine(sc, "INFOS " + list.size()); for (Event e : list) { sendInfo(sc, e); } }