Logo Search packages:      
Sourcecode: nailgun version File versions  Download package

com::martiansoftware::nailgun::ThreadLocalInputStream Class Reference

Inherits java::io::InputStream.

List of all members.

Detailed Description

The class name is pretty descriptive. This creates an InputStream much like a FilterInputStream, but with the wrapped InputStream being local to the current Thread. By setting System.in to a ThreadLocalInputStream, different Threads can read from different InputStreams simply by using System.in. Of course, the init() method must be called by the Thread that wishes to use the wrapped stream.

Marty Lamb

Definition at line 35 of file ThreadLocalInputStream.java.

Public Member Functions

int available () throws IOException
void close () throws IOException
void mark (int readlimit)
boolean markSupported ()
int read (byte[] b, int off, int len) throws IOException
int read (byte[] b) throws IOException
int read () throws IOException
void reset () throws IOException
long skip (long n) throws IOException

Package Functions

InputStream getInputStream ()
void init (InputStream streamForCurrentThread)
 ThreadLocalInputStream (InputStream defaultInputStream)

Private Attributes

InputStream defaultInputStream = null
InheritableThreadLocal streams = null

The documentation for this class was generated from the following file:

Generated by  Doxygen 1.6.0   Back to index