public class NullStream extends Stream
Stream.PrintMode
binary, convert, CR, DELIM, doneIn, doneOut, EOF, increment, LF, MODE_EXPORT, MODE_PUT_CONTROL, MODE_PUT_NORMAL, MODE_PUT_UNFORMATTED, NEWLINE, NEWLINE_LEN, PAGED_DEFAULT, PIPE_BROKEN_MESSAGE, SET_PAGED_DEFAULT, sourceCp, targetCp
Constructor and Description |
---|
NullStream()
Create a default instance.
|
Modifier and Type | Method and Description |
---|---|
void |
assign(Stream s)
Assigns the internal stream reference to the given reference, in
actuality this has no effect.
|
long |
available()
The number of bytes available to be immediately read without blocking.
|
protected void |
cleanup(boolean in,
boolean out)
Perform common close preprocessing for all streams, in actuality
this has no effect.
|
void |
close()
Closes the stream and releases OS resources associated with it, in
actuality this has no effect.
|
void |
closeIn()
Closes the input stream and releases OS resources associated with it,
in actuality this has no effect.
|
void |
closeOut()
Closes the output stream and releases OS resources associated with it,
in actuality this has no effect.
|
long |
getLen()
The length of the stream in bytes.
|
long |
getPos()
The 0-based offset into the stream at which the next read or write will
occur.
|
boolean |
isIn()
State of the input side of the stream.
|
boolean |
isOut()
State of the output side of the stream.
|
(package private) boolean |
needsPageBreak()
Detects when a page break is needed.
|
int |
peekCh()
Read a character from the current read position in the stream.
|
(package private) int |
rawGetNextLineNum()
Gets the current page's next line number.
|
(package private) int |
rawGetPageNum()
Gets the current page number.
|
(package private) int |
rawGetPageSize()
Gets the current page size in lines.
|
(package private) void |
rawIncrementNextLineNum()
Increments the current page's next line number, in actuality this has
no effect.
|
(package private) void |
rawIncrementPageNum()
Increments the current page number, in actuality this has no effect.
|
(package private) void |
rawResetNextLineNum()
Resets the current page's next line number to 1, in actuality this has
no effect.
|
(package private) void |
rawSetPageSize(int sz)
Sets the current page size in lines, in actuality this has no effect.
|
int |
readCh()
Read a character from the current read position in the stream.
|
java.lang.String |
readLn()
Read all characters from the current read position in the stream to the
next line separator (as determined by the
File.separator
or to the EOF . |
void |
setLen(long len)
Truncates or extends the stream to the specified length if this stream
supports such an operation, in actuality this has no effect.
|
void |
setPos(long pos)
Moves the current read/write position to the specified absolute 0-based
offset, in actuality this has no effect.
|
void |
write(byte[] data)
Write the given byte array to the output stream, in actuality this has
no effect.
|
void |
write(java.lang.String data)
Write the given string to the output stream, in actuality this has no
effect.
|
void |
writeByte(byte b)
Write the given byte to the output stream, in actuality this has no
effect.
|
void |
writeCh(char ch)
Write the given character to the output stream, in actuality this has
no effect.
|
advancePage, afterWrite, deleted, deregisterFooter, deregisterHeader, endOutput, endOutput, export, finished, flush, flushControlled, flushData, forcePageBreak, forcePageBreak, generateStringFormat, getAvailableLines, getControl, getConvert, getDelimiter, getDisplayMode, getEcho, getEffectivePageSize, getLength, getName, getNextLineNum, getPageNum, getPageSize, getPendingRowCount, getPosition, getUnformatted, hasPageHeadersFooters, indexOfNewLine, isContiguous, isFreshPage, isSilent, isSuppressFormFeed, isTerm, isUnbuffered, isUnnamed, isValid, iterate, needsHeadersOutput, needsPageBreak, processFooters, processHeaders, processHeadersInt, processHeadersUncond, protectReads, protectWrites, pulseOutput, put, putControl, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putField, putLineEnd, putLineEnd, putNull, putNull, putSpace, putSpace, putUnformatted, putWorker, rawNextLineNum, rawPageSize, readBlock, readChar, readChar, readChunk, readField, readField, readField, readField, readFieldWorker, readLine, readLineCleanup, registerAdvanceListener, registerCloseListener, registerFlushListener, registerFooter, registerHeader, registerPageBreakListener, resetCurrentLine, retry, setAppend, setBinary, setContiguous, setControl, setConvert, setConvertSource, setConvertSource, setConvertTarget, setConvertTarget, setDelimiter, setDelimiter, setEcho, setLandscape, setName, setPageSize, setPageSize, setPageSize, setPendingRowCount, setPortrait, setPosition, setPosition, setUnbuffered, setUnformatted, setUnnamed, skipField, skipLoneHyphenInput, startOutput, writeBlock, writeControlled, writeControlledSpecial, writeField, writeField, writeField, writeField, writeField
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
initFailure
public long available()
public long getPos()
public void setPos(long pos)
public boolean isIn()
public boolean isOut()
public long getLen()
public void setLen(long len)
public void writeCh(char ch)
public void writeByte(byte b)
public void write(java.lang.String data)
public void write(byte[] data)
public int peekCh()
public int readCh()
public java.lang.String readLn() throws java.io.EOFException
File.separator
or to the EOF
. Any line separator character(s) and the
EOF
character are not returned. In actuality this has no
effect.public void closeIn()
public void closeOut()
public void close()
public void assign(Stream s)
protected void cleanup(boolean in, boolean out) throws java.io.IOException
boolean needsPageBreak()
needsPageBreak
in class Stream
false
.int rawGetPageSize()
rawGetPageSize
in class Stream
void rawSetPageSize(int sz)
rawSetPageSize
in class Stream
sz
- Ignored.int rawGetPageNum()
rawGetPageNum
in class Stream
void rawIncrementPageNum()
rawIncrementPageNum
in class Stream
int rawGetNextLineNum()
rawGetNextLineNum
in class Stream
void rawIncrementNextLineNum()
rawIncrementNextLineNum
in class Stream
void rawResetNextLineNum()
rawResetNextLineNum
in class Stream