|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.io.Writer
org.ajax4jsf.resource.CountingOutputWriter
public class CountingOutputWriter
Class provides custom writer implementation with counting of bytes written Is using for replacement of css component writer
Field Summary | |
---|---|
static int |
sizeOfChar
Size of char type |
static int |
sizeOfInt
Size of int type |
Fields inherited from class java.io.Writer |
---|
lock |
Constructor Summary | |
---|---|
CountingOutputWriter()
Default constructor |
Method Summary | |
---|---|
void |
close()
|
void |
flush()
|
java.lang.StringBuffer |
getContent()
Methods gets content of written bytes |
int |
getWritten()
Methods gets written bytes count |
void |
write(char[] cbuf)
Methods appends chars written to buffer |
void |
write(char[] cbuf,
int off,
int len)
Methods appends chars written to buffer |
void |
write(int c)
Methods appends int written to buffer |
void |
write(java.lang.String str)
Methods appends string written to buffer |
void |
write(java.lang.String str,
int off,
int len)
Methods appends string written to buffer |
Methods inherited from class java.io.Writer |
---|
append, append, append |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int sizeOfChar
public static final int sizeOfInt
Constructor Detail |
---|
public CountingOutputWriter()
Method Detail |
---|
public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in class java.io.Writer
java.io.IOException
public void flush() throws java.io.IOException
flush
in interface java.io.Flushable
flush
in class java.io.Writer
java.io.IOException
public void write(char[] cbuf, int off, int len) throws java.io.IOException
write
in class java.io.Writer
cbuf
- - chars to be writtenoff
- - offsetlen
- - length of bytes
java.io.IOException
public void write(char[] cbuf) throws java.io.IOException
write
in class java.io.Writer
cbuf
- - chars to be written
java.io.IOException
public void write(int c) throws java.io.IOException
write
in class java.io.Writer
c
- - int to be written
java.io.IOException
public void write(java.lang.String str, int off, int len) throws java.io.IOException
write
in class java.io.Writer
str
- - string to be writtenoff
- - offsetlen
- - length of bytes
java.io.IOException
public void write(java.lang.String str) throws java.io.IOException
write
in class java.io.Writer
str
- - string to be written
java.io.IOException
public int getWritten()
public java.lang.StringBuffer getContent()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |