org.walluck.oscar.handlers
Class MiscHandler

java.lang.Object
  extended by org.walluck.oscar.handlers.SNACHandler
      extended by org.walluck.oscar.handlers.MiscHandler

public class MiscHandler
extends SNACHandler

Miscelaneous commands. I don't like this, but it won't really hurt to keep it.

Since:
1.0
Version:
1.0
Author:
David Walluck
See Also:
SNACHandler

Constructor Summary
MiscHandler()
          Group 0xffff.
 
Method Summary
 void genericReqInt(AIMSession sess, AIMConnection conn, int family, int subtype, int data)
          Send a request with a SNAC followed by an integer.
 void genericReqInt(AIMSession sess, AIMConnection conn, int family, int subtype, int data, boolean wantResponse)
          Send a request with a SNAC followed by an integer.
 void genericReqNull(AIMSession sess, AIMConnection conn, int family, int subtype)
          Generic method for sending commands.
 void genericReqNull(AIMSession sess, AIMConnection conn, int family, int subtype, boolean wantResponse)
          Generic method for sending commands.
 void genericReqNullSnacID(AIMSession sess, AIMConnection conn, int family, int subtype)
          Send a request with a null SNAC.
 void genericReqShort(AIMSession sess, AIMConnection conn, int family, int subtype, int data)
          Send a request with a SNAC followed by a short.
 void handleSNAC(AIMSession sess, SNACHandler handler, AIMFrame frame, SNAC snac, AIMInputStream buffer)
          Handles incoming SNAC's.
 
Methods inherited from class org.walluck.oscar.handlers.SNACHandler
getFamily, getVersion, setFamily, setVersion
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MiscHandler

public MiscHandler()
Group 0xffff.

Method Detail

genericReqNull

public void genericReqNull(AIMSession sess,
                           AIMConnection conn,
                           int family,
                           int subtype,
                           boolean wantResponse)
                    throws IOException
Generic method for sending commands.

Parameters:
sess - the oscar session
conn - the bos connection for this session
family - the SNAC family
subtype - the SNAC subtype
wantResponse - whether or not we want an ack for this message
Throws:
IOException - if an error occurs

genericReqNull

public void genericReqNull(AIMSession sess,
                           AIMConnection conn,
                           int family,
                           int subtype)
                    throws IOException
Generic method for sending commands.

Parameters:
sess - the oscar session
conn - the bos connection for this session
family - the SNAC family
subtype - the SNAC subtype
Throws:
IOException - if an error occurs

genericReqNullSnacID

public void genericReqNullSnacID(AIMSession sess,
                                 AIMConnection conn,
                                 int family,
                                 int subtype)
                          throws IOException
Send a request with a null SNAC.

Parameters:
sess - the oscar session
conn - the bos connection for this session
family - the SNAC family
subtype - the SNAC subtype
Throws:
IOException - if an error occurs

genericReqInt

public void genericReqInt(AIMSession sess,
                          AIMConnection conn,
                          int family,
                          int subtype,
                          int data,
                          boolean wantResponse)
                   throws IOException
Send a request with a SNAC followed by an integer. Allows you to set whether or not you want an ack. More of these may be added if needed.

Parameters:
sess - the oscar session
conn - the bos connection for this session
family - the SNAC family
subtype - the SNAC subtype
data - the integer data
wantResponse - whether or not we want an ack
Throws:
IOException - if an error occurs

genericReqInt

public void genericReqInt(AIMSession sess,
                          AIMConnection conn,
                          int family,
                          int subtype,
                          int data)
                   throws IOException
Send a request with a SNAC followed by an integer. With this version we want an ack.

Parameters:
sess - the oscar session
conn - the bos connection for this session
family - the SNAC family
subtype - the SNAC subtype
data - the integer data
Throws:
IOException - if an error occurs

genericReqShort

public void genericReqShort(AIMSession sess,
                            AIMConnection conn,
                            int family,
                            int subtype,
                            int data)
                     throws IOException
Send a request with a SNAC followed by a short.

Parameters:
sess - the oscar session
conn - the bos connection for this session
family - the SNAC family
subtype - the SNAC subtype
data - the short data
Throws:
IOException - if an error occurs

handleSNAC

public void handleSNAC(AIMSession sess,
                       SNACHandler handler,
                       AIMFrame frame,
                       SNAC snac,
                       AIMInputStream buffer)
                throws IOException
Handles incoming SNAC's.

Specified by:
handleSNAC in class SNACHandler
Parameters:
sess - the oscar session
handler - the handler
frame - the incoming frame
snac - the incoming SNAC
buffer - the incoming buffer
Throws:
IOException - if an error occurs