public class WriterAppender extends Writer implements Iterable<WriterAppender>
| Constructor and Description |
|---|
WriterAppender(Writer writer) |
| Modifier and Type | Method and Description |
|---|---|
Writer |
append(char c) |
Writer |
append(CharSequence csq) |
Writer |
append(CharSequence csq,
int start,
int end) |
void |
close() |
static WriterAppender |
create(Writer writer)
创建
|
void |
flush() |
WriterAppender |
getRoot()
获取根节点
|
Writer |
getWriter() |
void |
handle(Consumer<Writer> c)
处理流
|
Iterator<WriterAppender> |
iterator() |
WriterAppender |
onClose(boolean onClose)
close时是否关闭流
|
WriterAppender |
then(Writer writer)
连接下一个
|
void |
write(char[] cbuf) |
void |
write(char[] cbuf,
int off,
int len) |
void |
write(int b) |
void |
write(String str) |
void |
write(String str,
int off,
int len) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEach, spliteratorpublic WriterAppender(Writer writer)
public static WriterAppender create(Writer writer)
writer - writerpublic WriterAppender then(Writer writer)
writer - writerpublic WriterAppender onClose(boolean onClose)
onClose - onClosepublic WriterAppender getRoot()
public void write(int b)
throws IOException
write in class WriterIOExceptionpublic void write(char[] cbuf)
throws IOException
write in class WriterIOExceptionpublic void write(char[] cbuf,
int off,
int len)
throws IOException
write in class WriterIOExceptionpublic void write(String str) throws IOException
write in class WriterIOExceptionpublic void write(String str, int off, int len) throws IOException
write in class WriterIOExceptionpublic Writer append(char c) throws IOException
append in interface Appendableappend in class WriterIOExceptionpublic Writer append(CharSequence csq) throws IOException
append in interface Appendableappend in class WriterIOExceptionpublic Writer append(CharSequence csq, int start, int end) throws IOException
append in interface Appendableappend in class WriterIOExceptionpublic void close()
public void flush()
public Iterator<WriterAppender> iterator()
iterator in interface Iterable<WriterAppender>public Writer getWriter()
Copyright © 2025. All rights reserved.