Programming Tutorials Browser Tutorials Articles Struts Tutorials Hibernate Tutorials

  Tutorial: PircBot Java IRC API Resources

PircBot is a Java framework for writing IRC bots quickly and easily.

Tutorial Details:

Its features include an event-driven architecture to handle common IRC events, flood protection, DCC resuming support, ident support, and more. Its comprehensive logfile format is suitable for use with pisg to generate channel statistics. Full documentation is included, and this page contains a 5-minute step-by-step guide to making your first IRC bot.

PircBot allows you to perform a variety of fun tasks on IRC, but it is also used for more serious applications by the US Navy, the US Air Force, the CIA (unconfirmed) and several national defence agencies. But don't let that put you off - it's still easy to use!

In this example, we shall take you through how to make an IRC Bot that responds to a simple command. This should take no more than 5 minutes if you work fast. It will send a message to the channel saying what the local time is whenever someone says "time".

First, let's create a directory in which we can store the code for your IRC Bot. For this example, we shall be using c:\mybot\

Download the PircBot jar archive (see above) and save this in c:\mybot\

We now need to create our own IRC Bot by extending the functionality of PircBot. We can do this by creating MyBot.java in our directory (note that Java is case sensitive). To extend the PircBot without introducing any of our own functionality, all we need to do is put the following in the file named MyBot.java: -

import org.jibble.pircbot.*;

public class MyBot extends PircBot {

public MyBot() {
this.setName("MyBot");
}

}


 

Read Tutorial at: Click here to view the tutorial

Rate Tutorial:
PircBot Java IRC API Resources

View Tutorial:
PircBot Java IRC API Resources

Related Tutorials:

Java gets serial support with the new javax.comm package - JavaWorld - May 1998
Java gets serial support with the new javax.comm package - JavaWorld - May 1998
 
Java gets serial support with the new javax.comm package
Java gets serial support with the new javax.comm package
 
Program Java devices -- An overview - JavaWorld July 1999
Program Java devices -- An overview - JavaWorld July 1999
 
What's new in Java Servlet API 2.2? - JavaWorld October 1999
What's new in Java Servlet API 2.2? - JavaWorld October 1999
 
Easy Java/XML integration with JDOM, Part 1 - JavaWorld May 2000
Easy Java/XML integration with JDOM, Part 1 - JavaWorld May 2000
 
Code generation using Javadoc - JavaWorld August 2000
Code generation using Javadoc - JavaWorld August 2000
 
Mapping XML to Java, Part 1 - JavaWorld August 2000
Mapping XML to Java, Part 1 - JavaWorld August 2000
 
XML APIs for databases - JavaWorld January 2000
XML APIs for databases - JavaWorld January 2000
 
UDDI4J lets Java do the walking
UDDI4J lets Java do the walking
 
Introduction to the Java Mail API
Introduction to the Java Mail API
 
Dictionary and Thesaurus API for Java
What is the Dictionary and Thesaurus API for JavaTM? The Dictionary and Thesaurus API for Java is a standard-based class library for accessing a dictionary and thesaurus using Java. It provides programming access to wordbook data from the Java programm
 
Excelling in Excel with Java
Excelling in Excel with Java
 
PGP Java API 2.0
PGP Java API 2.0
 
Java SMPP API Homepage
Java SMPP API SMPP (Short Message Peer to Peer) is a protocol used by short message entities (SMEs) to communicate with Short Message Service Centres (SMSC, or just SC) for sending an receiving short messages.
 
IRC Text to Speech with Java
This article will show you how to create a multi-platform IRC bot (an automated client) that uses the FreeTTS Java speech synthesizer library to convert IRC messages into audible speech.
 
Using SSL with Non-Blocking IO
Using SSL with Non-Blocking IO After the initial experiments with Java NIO, most developers start wondering about security; in particular, how to use SSL with Java NIO. With the traditional blocking sockets API, security is a simple issue: just set up an
 
JTwain
JTwain will implement a Java interface to the the Win32 C DLL TWAIN acquire methods.
 
Getting Started with Java Management Extensions (JMX): Developing Management and Monitoring Solutions
The Java Management Extensions (JMX) API is a standard specification developed through the Java Community Process (JCP) as JSR 3 for managing and monitoring applications and services.
 
Buy SuSe 9.1 Personal CDs in India from us. Suse 9.1 Personal is available with us.
Buy SuSe 9.1 Personal CDs in India from us. Suse 9.1 Personal is available with us. SuSe 9.1 Personal Linux Now Available SuSe 9.1 Personal CD's SuSE 9.1 Personal Edition was based on the x86 port of the Personal Edition, and it includes all of
 
Techniques used for Generating Dynamic Content Using Java Servlets.
Techniques used for Generating Dynamic Content Using Java Servlets. Techniques used for Generating Dynamic Content Common Gateway Interface (CGI) For any web application high performance and timely delivery are key ingredients to competitive
 
Site navigation
 

 

Send your comments, Suggestions or Queries regarding this site at roseindia_net@yahoo.com.

Copyright © 2006. All rights reserved.