com.ctc.wstx.io
Class UTFAttrValueWriter
java.lang.Object
java.io.Writer
java.io.FilterWriter
com.ctc.wstx.io.WriterBase
com.ctc.wstx.io.UTFAttrValueWriter
- All Implemented Interfaces:
- java.io.Closeable, java.io.Flushable, java.lang.Appendable
public class UTFAttrValueWriter
- extends WriterBase
Escaping writer that will properly escape characters from the attribute
values that need to be escaped, when outputting using "native" Unicode
aware Writer.
Fields inherited from class java.io.FilterWriter |
out |
Fields inherited from class java.io.Writer |
lock |
Constructor Summary |
UTFAttrValueWriter(java.io.Writer out,
java.lang.String enc,
char qchar,
boolean escapeCR)
|
Method Summary |
void |
write(char[] cbuf,
int offset,
int len)
|
void |
write(int c)
|
void |
write(java.lang.String str,
int offset,
int len)
|
Methods inherited from class java.io.FilterWriter |
close, flush |
Methods inherited from class java.io.Writer |
append, append, append, write, write |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UTFAttrValueWriter
public UTFAttrValueWriter(java.io.Writer out,
java.lang.String enc,
char qchar,
boolean escapeCR)
- Parameters:
enc
- Name of actual encoding in use; ignored for UTF
writersescapeCR
- If true, will encode \r character; if false, will
output as is (former is needed for reliable round-tripping, but
adds verbosity without necessary benefits)
write
public void write(int c)
throws java.io.IOException
- Overrides:
write
in class java.io.FilterWriter
- Throws:
java.io.IOException
write
public void write(char[] cbuf,
int offset,
int len)
throws java.io.IOException
- Overrides:
write
in class java.io.FilterWriter
- Throws:
java.io.IOException
write
public void write(java.lang.String str,
int offset,
int len)
throws java.io.IOException
- Overrides:
write
in class java.io.FilterWriter
- Throws:
java.io.IOException