org.jabber.jabberbeans.sax
Class InputStreamHandler

java.lang.Object
  |
  +--java.lang.Thread
        |
        +--org.jabber.jabberbeans.sax.InputStreamHandler
All Implemented Interfaces:
java.lang.Runnable

public final class InputStreamHandler
extends java.lang.Thread

Creates a thread and handles the input part of an XMLStream via a SAX parser


Field Summary
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
InputStreamHandler(ConnectionBean.InputStreamInterface isi)
          Creates a new InputStreamHandler instance.
 
Method Summary
 java.lang.String getParser()
           
 void received(Packet p)
          received is a method for other objects to broadcast packets recognised on the inputStream up to the ConnectionBean
 void run()
          Main thread body, creates the parser, associates the XMLStream DocumentHandler, and starts everything running.
 void setInputStream(java.io.InputStream in)
           
 void setParser(java.lang.String parsername)
           
 void shutdown()
           
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

InputStreamHandler

public InputStreamHandler(ConnectionBean.InputStreamInterface isi)
Creates a new InputStreamHandler instance.

Method Detail

setInputStream

public void setInputStream(java.io.InputStream in)

run

public final void run()
Main thread body, creates the parser, associates the XMLStream DocumentHandler, and starts everything running.

Specified by:
run in interface java.lang.Runnable
Overrides:
run in class java.lang.Thread

received

public void received(Packet p)
received is a method for other objects to broadcast packets recognised on the inputStream up to the ConnectionBean

Parameters:
p - a Packet which was just received and recognised.

shutdown

public void shutdown()

setParser

public void setParser(java.lang.String parsername)

getParser

public java.lang.String getParser()