public class SourceResponse extends Object
Constructor and Description |
---|
SourceResponse(SourceConfiguration config,
int status,
SourceRequest request) |
SourceResponse(SourceConfiguration config,
int status,
String statusLine,
SourceRequest request) |
Modifier and Type | Method and Description |
---|---|
void |
addHeader(String name,
String value) |
void |
checkResponseChunkDisable(org.apache.axis2.context.MessageContext responseMsgContext) |
void |
connect(Pipe pipe) |
String |
getHeader(String name) |
boolean |
hasEntity() |
void |
removeHeader(String name) |
void |
setKeepAlive(boolean keepAlive) |
void |
setStatus(int status) |
void |
start(org.apache.http.nio.NHttpServerConnection conn)
Starts the response by writing the headers
|
int |
write(org.apache.http.nio.NHttpServerConnection conn,
org.apache.http.nio.ContentEncoder encoder)
Consume the content through the Pipe and write them to the wire
|
public SourceResponse(SourceConfiguration config, int status, SourceRequest request)
public SourceResponse(SourceConfiguration config, int status, String statusLine, SourceRequest request)
public void connect(Pipe pipe)
public void start(org.apache.http.nio.NHttpServerConnection conn) throws IOException, org.apache.http.HttpException
conn
- connectionIOException
- if an error occursorg.apache.http.HttpException
- if an error occurspublic void checkResponseChunkDisable(org.apache.axis2.context.MessageContext responseMsgContext) throws IOException
IOException
public int write(org.apache.http.nio.NHttpServerConnection conn, org.apache.http.nio.ContentEncoder encoder) throws IOException
conn
- connectionencoder
- encoderIOException
- if an error occurspublic void setStatus(int status)
public void removeHeader(String name)
public boolean hasEntity()
public void setKeepAlive(boolean keepAlive)
Copyright © 2005–2017 Apache Software Foundation. All rights reserved.