public class MuxInputStream
extends java.io.InputStream
Modifier and Type | Field and Description |
---|---|
protected java.io.InputStream |
is |
Constructor and Description |
---|
MuxInputStream()
Null argument constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Complete writing to the stream, closing the channel.
|
int |
getChannel()
Gets the channel of the connection.
|
protected java.io.InputStream |
getInputStream()
Gets the raw input stream.
|
java.lang.String |
getURL()
Returns the request's URL
|
protected void |
init(MuxServer server,
int channel)
Initialize the multiplexor with input and output streams.
|
int |
read()
Writes a data byte to the output stream.
|
protected void |
readTag(int tag)
Subclasses will extend this to read values.
|
protected java.lang.String |
readUTF()
Reads a UTF-8 string.
|
protected void init(MuxServer server, int channel) throws java.io.IOException
java.io.IOException
protected java.io.InputStream getInputStream() throws java.io.IOException
java.io.IOException
public int getChannel()
public java.lang.String getURL()
public int read() throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class java.io.InputStream
java.io.IOException
protected void readTag(int tag) throws java.io.IOException
java.io.IOException
protected java.lang.String readUTF() throws java.io.IOException
java.io.IOException