|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.caucho.quercus.lib.file.AbstractBinaryInputOutput
com.caucho.quercus.lib.file.BufferedBinaryInputOutput
public abstract class BufferedBinaryInputOutput
Represents a Quercus file open for reading
Field Summary |
---|
Fields inherited from class com.caucho.quercus.lib.file.AbstractBinaryInputOutput |
---|
_env, _isEOF, _isTimeout, _lineReader |
Fields inherited from interface com.caucho.quercus.lib.file.BinaryStream |
---|
SEEK_CUR, SEEK_END, SEEK_SET |
Constructor Summary | |
---|---|
protected |
BufferedBinaryInputOutput(Env env)
|
Method Summary | |
---|---|
int |
getAvailable()
|
long |
getPosition()
Returns the current location in the file. |
void |
init(ReadStream is,
WriteStream os)
|
int |
read()
Reads a character from a file, returning -1 on EOF. |
int |
read(char[] buffer,
int offset,
int length)
Reads a buffer from a file, returning -1 on EOF. |
StringValue |
readLine(long length)
Reads a line from a file, returning null on EOF. |
void |
setEncoding(java.lang.String encoding)
|
boolean |
setPosition(long offset)
Sets the current location in the file. |
Value |
stat()
Returns an array filled with stat information. |
java.lang.String |
toString()
Converts to a string. |
void |
unread()
Unread the last byte. |
void |
writeToStream(java.io.OutputStream os,
int length)
|
Methods inherited from class com.caucho.quercus.lib.file.AbstractBinaryInputOutput |
---|
appendTo, close, closeRead, closeWrite, flush, getEnv, getInputStream, getOutputStream, getResourceType, init, isEOF, isTimeout, openCopy, print, print, read, read, readOptionalLinefeed, seek, setTimeout, toJavaObject, write, write, write |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
protected BufferedBinaryInputOutput(Env env)
Method Detail |
---|
public void init(ReadStream is, WriteStream os)
public void setEncoding(java.lang.String encoding) throws java.io.UnsupportedEncodingException
java.io.UnsupportedEncodingException
public void unread() throws java.io.IOException
unread
in interface BinaryInput
unread
in class AbstractBinaryInputOutput
java.io.IOException
public int getAvailable() throws java.io.IOException
getAvailable
in interface BinaryInput
getAvailable
in class AbstractBinaryInputOutput
java.io.IOException
public int read() throws java.io.IOException
read
in interface BinaryInput
read
in class AbstractBinaryInputOutput
java.io.IOException
public int read(char[] buffer, int offset, int length) throws java.io.IOException
java.io.IOException
public void writeToStream(java.io.OutputStream os, int length) throws java.io.IOException
java.io.IOException
public StringValue readLine(long length) throws java.io.IOException
readLine
in interface BinaryInput
readLine
in class AbstractBinaryInputOutput
java.io.IOException
public long getPosition()
getPosition
in interface BinaryInput
getPosition
in interface BinaryStream
getPosition
in class AbstractBinaryInputOutput
public boolean setPosition(long offset)
setPosition
in interface BinaryInput
setPosition
in interface BinaryStream
setPosition
in class AbstractBinaryInputOutput
public Value stat()
BinaryStream
stat
in interface BinaryStream
stat
in class AbstractBinaryInputOutput
public java.lang.String toString()
toString
in class AbstractBinaryInputOutput
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |