|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.http.impl.io.AbstractMessageWriter<T>
public abstract class AbstractMessageWriter<T extends HttpMessage>
Abstract base class for HTTP message writers that serialize output to
an instance of SessionOutputBuffer.
| Field Summary | |
|---|---|
protected CharArrayBuffer |
lineBuf
|
protected LineFormatter |
lineFormatter
|
protected SessionOutputBuffer |
sessionBuffer
|
| Constructor Summary | |
|---|---|
AbstractMessageWriter(SessionOutputBuffer buffer,
LineFormatter formatter)
Creates an instance of AbstractMessageWriter. |
|
AbstractMessageWriter(SessionOutputBuffer buffer,
LineFormatter formatter,
HttpParams params)
Deprecated. (4.3) use AbstractMessageWriter(SessionOutputBuffer, LineFormatter) |
|
| Method Summary | |
|---|---|
void |
write(T message)
Serializes an instance of HttpMessage to the underlying data
sink. |
protected abstract void |
writeHeadLine(T message)
Subclasses must override this method to write out the first header line based on the HttpMessage passed as a parameter. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final SessionOutputBuffer sessionBuffer
protected final CharArrayBuffer lineBuf
protected final LineFormatter lineFormatter
| Constructor Detail |
|---|
@Deprecated
public AbstractMessageWriter(SessionOutputBuffer buffer,
LineFormatter formatter,
HttpParams params)
AbstractMessageWriter(SessionOutputBuffer, LineFormatter)
buffer - the session output buffer.formatter - the line formatter.params - HTTP parameters.
public AbstractMessageWriter(SessionOutputBuffer buffer,
LineFormatter formatter)
buffer - the session output buffer.formatter - the line formatter If null BasicLineFormatter.INSTANCE
will be used.| Method Detail |
|---|
protected abstract void writeHeadLine(T message)
throws IOException
HttpMessage passed as a parameter.
message - the message whose first line is to be written out.
IOException - in case of an I/O error.
public void write(T message)
throws IOException,
HttpException
HttpMessageWriterHttpMessage to the underlying data
sink.
write in interface HttpMessageWriter<T extends HttpMessage>message - HTTP message
IOException - in case of an I/O error
HttpException - in case of HTTP protocol violation
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||