|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.io.Writer
java.io.PrintWriter
org.codehaus.groovy.grails.web.util.GrailsPrintWriter
public class GrailsPrintWriter
PrintWriter implementation that doesn't have synchronization. null object references are ignored in print methods (nothing gets printed)
| Field Summary | |
|---|---|
protected boolean |
allowUnwrappingOut
|
protected Writer |
out
|
protected boolean |
trouble
|
| Fields inherited from class java.io.Writer |
|---|
lock |
| Constructor Summary | |
|---|---|
GrailsPrintWriter(Writer out)
|
|
| Method Summary | |
|---|---|
PrintWriter |
append(char c)
|
PrintWriter |
append(CharSequence csq)
|
PrintWriter |
append(CharSequence csq,
int start,
int end)
|
GrailsPrintWriter |
append(Object obj)
|
void |
append(StreamCharBuffer otherBuffer)
|
boolean |
checkError()
Flush the stream if it's not closed and check its error state. |
protected Object |
clone()
|
void |
flush()
Flush the stream. |
Writer |
getFinalTarget()
|
Writer |
getOut()
|
protected void |
handleIOException(IOException e)
|
boolean |
isAllowUnwrappingOut()
|
boolean |
isFinalTargetHere()
|
boolean |
isUsed()
|
GrailsPrintWriter |
leftShift(Object value)
Provides Groovy << left shift operator, but intercepts call to make sure nulls are converted to "" strings |
GrailsPrintWriter |
leftShift(StreamCharBuffer otherBuffer)
|
GrailsPrintWriter |
leftShift(groovy.lang.Writable writable)
|
GrailsPrintWriter |
plus(Object value)
|
void |
print(boolean b)
delegate methods, not synchronized |
void |
print(char c)
|
void |
print(char[] s)
|
void |
print(double d)
|
void |
print(float f)
|
void |
print(int i)
|
void |
print(long l)
|
void |
print(Object obj)
Print an object. |
void |
print(StreamCharBuffer otherBuffer)
|
void |
print(String s)
Print a string. |
void |
print(groovy.lang.Writable writable)
|
void |
println()
|
void |
println(boolean b)
|
void |
println(char c)
|
void |
println(char[] c)
|
void |
println(double d)
|
void |
println(float f)
|
void |
println(int i)
|
void |
println(long l)
|
void |
println(Object o)
|
void |
println(StreamCharBuffer otherBuffer)
|
void |
println(String s)
|
boolean |
resetUsed()
|
void |
setFinalTargetHere(boolean finalTargetHere)
|
void |
setUsed(boolean newUsed)
|
void |
write(char[] buf)
|
void |
write(char[] buf,
int off,
int len)
Write a portion of an array of characters. |
void |
write(int c)
Write a single character. |
void |
write(StreamCharBuffer otherBuffer)
|
void |
write(String s)
Writes a string. |
void |
write(String s,
int off,
int len)
Write a portion of a string. |
void |
write(groovy.lang.Writable writable)
|
| Methods inherited from class java.io.PrintWriter |
|---|
close, format, format, printf, printf, setError |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected boolean trouble
protected Writer out
protected boolean allowUnwrappingOut
| Constructor Detail |
|---|
public GrailsPrintWriter(Writer out)
| Method Detail |
|---|
public boolean isAllowUnwrappingOut()
public Writer getOut()
public boolean isFinalTargetHere()
public void setFinalTargetHere(boolean finalTargetHere)
public Writer getFinalTarget()
public GrailsPrintWriter leftShift(Object value)
throws IOException
value - The value
IOException
public GrailsPrintWriter plus(Object value)
throws IOException
IOExceptionpublic boolean checkError()
checkError in class PrintWriterpublic void flush()
flush in interface Flushableflush in class PrintWritercheckError()protected void handleIOException(IOException e)
public void print(Object obj)
String.valueOf(Object) method is translated into bytes
according to the platform's default character encoding, and these bytes
are written in exactly the manner of the write(int)
method.
print in class PrintWriterobj - The Object to be printedObject.toString()public void print(String s)
null then the string
"" is printed. Otherwise, the string's characters are
converted into bytes according to the platform's default character
encoding, and these bytes are written in exactly the manner of the
write(int) method.
print in class PrintWriters - The String to be printedpublic void write(String s)
null then the string
"" is printed.
write in class PrintWriters - The String to be printedpublic void write(int c)
write in class PrintWriterc - int specifying a character to be written.
public void write(char[] buf,
int off,
int len)
write in class PrintWriterbuf - Array of charactersoff - Offset from which to start writing characterslen - Number of characters to write
public void write(String s,
int off,
int len)
write in class PrintWriters - A Stringoff - Offset from which to start writing characterslen - Number of characters to writepublic void write(char[] buf)
write in class PrintWriterpublic void print(boolean b)
print in class PrintWriterpublic void print(char c)
print in class PrintWriterpublic void print(int i)
print in class PrintWriterpublic void print(long l)
print in class PrintWriterpublic void print(float f)
print in class PrintWriterpublic void print(double d)
print in class PrintWriterpublic void print(char[] s)
print in class PrintWriterpublic void println()
println in class PrintWriterpublic void println(boolean b)
println in class PrintWriterpublic void println(char c)
println in class PrintWriterpublic void println(int i)
println in class PrintWriterpublic void println(long l)
println in class PrintWriterpublic void println(float f)
println in class PrintWriterpublic void println(double d)
println in class PrintWriterpublic void println(char[] c)
println in class PrintWriterpublic void println(String s)
println in class PrintWriterpublic void println(Object o)
println in class PrintWriterpublic PrintWriter append(char c)
append in interface Appendableappend in class PrintWriter
public PrintWriter append(CharSequence csq,
int start,
int end)
append in interface Appendableappend in class PrintWriterpublic PrintWriter append(CharSequence csq)
append in interface Appendableappend in class PrintWriterpublic GrailsPrintWriter append(Object obj)
protected Object clone()
throws CloneNotSupportedException
clone in class ObjectCloneNotSupportedExceptionpublic void write(StreamCharBuffer otherBuffer)
public void print(StreamCharBuffer otherBuffer)
public void append(StreamCharBuffer otherBuffer)
public void println(StreamCharBuffer otherBuffer)
public GrailsPrintWriter leftShift(StreamCharBuffer otherBuffer)
public void write(groovy.lang.Writable writable)
public void print(groovy.lang.Writable writable)
public GrailsPrintWriter leftShift(groovy.lang.Writable writable)
public boolean isUsed()
public void setUsed(boolean newUsed)
public boolean resetUsed()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||