JspWriter Class | |
public abstract class JspWriter extends Writer | |
Object Writer JspWriter The JspWriter class provides a character output stream that can be used by a JSP object. It provides overloaded versions of the print() and println() methods that can handle primitive and String datatypes. |
JspWriter() | |
protected JspWriter(int bufferSize, boolean autoFlush) | Constructor |
The JspWriter class is abstract, so a JspWriter object is not created directly. This constructor can be used by sub-classes of JspWriter. |
clear() | |
public abstract void clear() throws IOException | Method |
clear() clears the contents of the buffer. This method throws an exception if some data has already been written to the output stream. |
clearBuffer() | |
public abstract void clearBuffer() throws IOException | Method |
clearBuffer() clears the contents of the buffer but does not throw an exception is some data has already been written to the output stream. |
close() | |
public abstract void close() throws IOException | Method |
close() flushes and then closes the output stream. |
flush() | |
public abstract void flush() throws IOException | Method |
flush() flushes the output buffer and sends any bytes contained in the buffer to their intended destination. |
getBufferSize() | |
public int getBufferSize() | Method |
getBufferSize() returns the size in bytes of the output buffer. |
getRemaining() | |
public abstract int getRemaining() | Method |
getRemaining() returns the number of bytes still contained in the buffer. |
isAutoFlush() | |
public boolean isAutoFlush() | Method |
isAutoFlush() returns true if the buffer flushes automatically when an overflow condition occurs. |
newLine() | |
public abstract void newLine() throws IOException | Method |
newLine() writes a system-dependent newline character to the output stream. |
print() | |
public abstract void print(boolean b) throws IOException public abstract void print(char c) throws IOException public abstract void print(char[] charArray) throws IOException public abstract void print(double d) throws IOException public abstract void print(float f) throws IOException public abstract void print(int i) throws IOException public abstract void print(long l) throws IOException public abstract void print(Object obj) throws IOException public abstract void print(String str) throws IOException |
Method |
print() printsthe specified primitive datatype, Object or String to the client without a carriage return/line feed character at the end. If an Object argument is passed, it is converted to a String using the String.valueOf() method. |
println() | |
public abstract void println() throws IOException public abstract void println(boolean b) throws IOException public abstract void println(char c) throws IOException public abstract void println(char[] charArray) throws IOException public abstract void println(double d) throws IOException public abstract void println(float f) throws IOException public abstract void println(int i) throws IOException public abstract void println(long l) throws IOException public abstract void println(Object obj) throws IOException public abstract void println(String str) throws IOException |
Method |
print() prints the specified primitive datatype, Object or String to the client followed by a carriage return/line feed character at the end. The no-argument version simply writes a carriage return/line feed. If an Object argument is passed, it is converted to a String using the String.valueOf() method. |