|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.xnap.plugin.AbstractPlugin org.xnap.plugin.joscar.JOscarPlugin
public class JOscarPlugin
Provides a simple chat plugin for ICQ. This class creates the connection to the oscar server and is responsible of managing the buddies and open chat channels, it also updates the online status of each buddy.
Field Summary | |
---|---|
static java.lang.String |
BUDDY_FILE
|
static javax.swing.Icon |
ICON_16
|
static java.lang.String |
ICON_FILENAME
|
Constructor Summary | |
---|---|
JOscarPlugin()
|
Method Summary | |
---|---|
JOscarPeer |
addBuddy(JOscarPeer buddy)
Creates a new JOscarPeer if it's not already in the
buddies hashtable. |
JOscarPeer |
addBuddy(java.lang.String uin)
Creates a new JOscarPeer if it's not already in the
buddies hashtable. |
void |
addChannel(JOscarChannel channel)
|
JOscarConnection |
getConnection()
Returns the oscar connection for listeners to subscribe to. |
static JOscarPlugin |
getInstance()
|
JOscarPeer |
getLocalPeer()
Returns the local peer. |
java.lang.String |
getName()
Returns the name of the plugin. |
void |
onIncomingMessage(JOscarLib.Integration.Event.IncomingMessageEvent event)
Implements the OscarListener interface. |
void |
onIncomingUrl(JOscarLib.Integration.Event.IncomingUrlEvent e)
Implements the OscarListener interface. |
void |
onIncomingUser(JOscarLib.Integration.Event.IncomingUserEvent e)
Implements the OscarListener interface. |
void |
onOffgoingUser(JOscarLib.Integration.Event.OffgoingUserEvent e)
Implements the OscarListener interface. |
void |
onOfflineMessage(JOscarLib.Integration.Event.OfflineMessageEvent e)
Implements the OscarListener interface. |
void |
propertyChange(java.beans.PropertyChangeEvent e)
|
void |
removeBuddy(JOscarPeer buddy)
Removes a buddy. |
void |
removeChannel(JOscarChannel channel)
|
void |
sendMessage(java.lang.String uin,
java.lang.String message)
|
void |
sendSMS(java.lang.String uin,
java.lang.String message)
|
void |
start()
Starts the plugin. |
void |
startGUI()
Starts the GUI of the plugin. |
void |
stateChanged(StateEvent event)
Invoked when the object has changed. |
void |
stop()
Stops the plugin. |
void |
stopGUI()
Stops the GUI of the plugin. |
Methods inherited from class org.xnap.plugin.AbstractPlugin |
---|
getInfo, setInfo, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static java.lang.String ICON_FILENAME
public static javax.swing.Icon ICON_16
public static final java.lang.String BUDDY_FILE
Constructor Detail |
---|
public JOscarPlugin()
Method Detail |
---|
public static JOscarPlugin getInstance()
public java.lang.String getName()
public void start()
start
in interface Plugin
public void startGUI()
startGUI
in interface Plugin
public void stop()
stop
in interface Plugin
public void propertyChange(java.beans.PropertyChangeEvent e)
propertyChange
in interface java.beans.PropertyChangeListener
public void stateChanged(StateEvent event)
StateListener
stateChanged
in interface StateListener
public void stopGUI()
stopGUI
in interface Plugin
public void sendMessage(java.lang.String uin, java.lang.String message)
public void sendSMS(java.lang.String uin, java.lang.String message)
public JOscarPeer addBuddy(java.lang.String uin)
JOscarPeer
if it's not already in the
buddies
hashtable.
public JOscarPeer addBuddy(JOscarPeer buddy)
JOscarPeer
if it's not already in the
buddies
hashtable.
public JOscarPeer getLocalPeer()
public JOscarConnection getConnection()
public void removeBuddy(JOscarPeer buddy)
public void addChannel(JOscarChannel channel)
public void removeChannel(JOscarChannel channel)
public void onIncomingMessage(JOscarLib.Integration.Event.IncomingMessageEvent event)
OscarListener
interface.
onIncomingMessage
in interface JOscarLib.Integration.Event.MessagingListener
public void onIncomingUrl(JOscarLib.Integration.Event.IncomingUrlEvent e)
OscarListener
interface.
onIncomingUrl
in interface JOscarLib.Integration.Event.MessagingListener
public void onIncomingUser(JOscarLib.Integration.Event.IncomingUserEvent e)
OscarListener
interface.
onIncomingUser
in interface JOscarLib.Integration.Event.StatusListener
public void onOffgoingUser(JOscarLib.Integration.Event.OffgoingUserEvent e)
OscarListener
interface.
onOffgoingUser
in interface JOscarLib.Integration.Event.StatusListener
public void onOfflineMessage(JOscarLib.Integration.Event.OfflineMessageEvent e)
OscarListener
interface.
onOfflineMessage
in interface JOscarLib.Integration.Event.MessagingListener
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |