public class Ajp13Generator extends AbstractGenerator
_buffer, _buffers, _content, _contentLength, _contentWritten, _date, _endp, _head, _header, _last, _method, _noContent, _persistent, _reason, _state, _status, _uri, _version, NO_BYTES, STATE_CONTENT, STATE_END, STATE_FLUSHING, STATE_HEADER
Constructor and Description |
---|
Ajp13Generator(Buffers buffers,
EndPoint io) |
Modifier and Type | Method and Description |
---|---|
void |
addContent(Buffer content,
boolean last)
Add content.
|
void |
complete()
Complete the message.
|
void |
completeHeader(HttpFields fields,
boolean allContentAdded) |
int |
flushBuffer() |
void |
getBodyChunk() |
int |
getContentBufferSize() |
void |
gotBody() |
void |
increaseContentBufferSize(int contentBufferSize) |
boolean |
isComplete() |
boolean |
isRequest() |
boolean |
isResponse() |
int |
prepareUncheckedAddContent()
Prepare buffer for unchecked writes.
|
void |
reset() |
void |
sendCPong() |
static void |
setServerVersion(String version) |
blockForOutput, completeUncheckedAddContent, flush, getContentWritten, getSendServerVersion, getState, getUncheckedBuffer, getVersion, isAllContentWritten, isBufferFull, isCommitted, isHead, isIdle, isOpen, isPersistent, isState, isWritten, resetBuffer, returnBuffers, sendError, setContentLength, setDate, setHead, setPersistent, setRequest, setResponse, setSendServerVersion, setVersion
public static void setServerVersion(String version)
public boolean isRequest()
isRequest
in class AbstractGenerator
public boolean isResponse()
isResponse
in class AbstractGenerator
public void reset()
reset
in interface Generator
reset
in class AbstractGenerator
public int getContentBufferSize()
getContentBufferSize
in interface Generator
getContentBufferSize
in class AbstractGenerator
public void increaseContentBufferSize(int contentBufferSize)
increaseContentBufferSize
in interface Generator
increaseContentBufferSize
in class AbstractGenerator
contentBufferSize
- The contentBufferSize to set.public void addContent(Buffer content, boolean last) throws IOException
content
- last
- IllegalArgumentException
- if content
is immutable
.IllegalStateException
- If the request is not expecting any more content, or if the buffers are full and cannot be flushed.IOException
- if there is a problem flushing the buffers.public int prepareUncheckedAddContent() throws IOException
prepareUncheckedAddContent
in class AbstractGenerator
IOException
public void completeHeader(HttpFields fields, boolean allContentAdded) throws IOException
completeHeader
in interface Generator
completeHeader
in class AbstractGenerator
IOException
public void complete() throws IOException
complete
in interface Generator
complete
in class AbstractGenerator
IOException
public int flushBuffer() throws IOException
flushBuffer
in interface Generator
flushBuffer
in class AbstractGenerator
IOException
public boolean isComplete()
isComplete
in interface Generator
isComplete
in class AbstractGenerator
public void getBodyChunk() throws IOException
IOException
public void gotBody()
public void sendCPong() throws IOException
IOException
Copyright © 1995-2013 Mort Bay Consulting. All Rights Reserved.