Covert, Mark
 

J2IRC: A Java IRC client

Mark Covert

Presented: April 2004

Project Advisor: Susan Reiser

Background:

Internet Relay Chat (IRC) is a distributed, text based conferencing system relying on the client/server model. The simplest client is one who is capable of opening a socket connection to a server (RFC 1459). IRC allows users from around the world to connect and communicate with one another in formal channels or through private chat sessions. The value of this resource and the desire for a more user-friendly interface motivated me to create my own IRC client.

Purpose:

The goal of this project was to learn Java while creating a simple, user-friendly IRC client. J2IRC is written in Java 2 Standard Edition 1.4 and is designed to connect to any RFC 1459 compliant server. I chose Java for this project in hopes that this application can provide a consistent IRC experience for users of any operating system for which the Java Runtime Environment is available.

The Program:

J2IRC takes advantage of Java's Swing classes for its graphical user interface. The interface is intended to be simple and intuitive, while still including access to important IRC commands. The requisite network connections are built using Java's Socket class. Threads are used to prevent blocking the user interface while lengthy operations are processing.

Features:

  • Ability to connect to an arbitrary IRC server or one selected from a pre-determined list

  • Error checking with meaningful error messages
  • Multi-threaded to keep GUI responsive while network data is parsed
  • Allows user to join multiple channels simultaneously. Parsing algorithm ensures that text is directed to appropriate channels
  • Channels open in separate windows to allow for convenient screen placement

  • Channels display lists of current users and support access to user-specific commands through right-clicking

  • Supports initiating and receiving Direct Client-to-Client (DCC) chat sessions

  • Listens and responds to requests from the Identification Protocol on port 113 (RFC 1413)

Conclusion:

J2IRC is the result of over a year's worth of research, design, and coding. This project has allowed me to explore important areas of software development such as GUI creation, algorithmic design, and network programming. Since most of my prior programming experience was in C++, this project has given me the opportunity to learn and apply Java in a complex application. In addition, this project has helped me to understand the intricacies of programming for compliance with an existing standard such as the IRC protocol.

RFC 1459: http://www.irchelp.org/irchelp/rfc/chapter1.html

RFC 1413: http://www.faqs.org/rfcs/rfc1413.html