public abstract class OHttpResponse extends Object
Modifier and Type | Field and Description |
---|---|
static String |
JSON_FORMAT |
static char[] |
URL_SEPARATOR |
protected static Charset |
utf8 |
Constructor and Description |
---|
OHttpResponse(OutputStream iOutStream,
String iHttpVersion,
String[] iAdditionalHeaders,
String iResponseCharSet,
String iServerInfo,
String iSessionId,
String iCallbackFunction,
boolean iKeepAlive,
OClientConnection connection,
OContextConfiguration contextConfiguration) |
Modifier and Type | Method and Description |
---|---|
void |
addHeader(String name,
String value) |
protected abstract void |
checkConnection() |
byte[] |
compress(String jsonStr) |
void |
flush() |
void |
formatMultiValue(Iterator<?> iIterator,
Writer buffer,
String format) |
String[] |
getAdditionalHeaders() |
String |
getCallbackFunction() |
String |
getCharacterSet() |
int |
getCode() |
OClientConnection |
getConnection() |
String |
getContent() |
String |
getContentEncoding() |
String |
getContentType() |
OContextConfiguration |
getContextConfiguration() |
String |
getHeaders() |
Map<String,String> |
getHeadersMap() |
String |
getHttpVersion() |
OutputStream |
getOut() |
OutputStream |
getOutputStream() |
String |
getServerInfo() |
String |
getSessionId() |
String |
getStaticEncoding() |
boolean |
isJsonErrorResponse() |
boolean |
isKeepAlive() |
boolean |
isSameSiteCookie() |
boolean |
isSendStarted() |
boolean |
isStreaming() |
abstract void |
send(int iCode,
String iReason,
String iContentType,
Object iContent,
String iHeaders) |
abstract void |
sendStream(int iCode,
String iReason,
String iContentType,
InputStream iContent,
long iSize) |
abstract void |
sendStream(int iCode,
String iReason,
String iContentType,
InputStream iContent,
long iSize,
String iFileName) |
abstract void |
sendStream(int iCode,
String iReason,
String iContentType,
InputStream iContent,
long iSize,
String iFileName,
Map<String,String> additionalHeaders) |
abstract void |
sendStream(int iCode,
String iReason,
String iContentType,
String iFileName,
OCallable<Void,OChunkedResponse> iWriter) |
void |
setAdditionalHeaders(String[] additionalHeaders) |
void |
setCallbackFunction(String callbackFunction) |
void |
setCharacterSet(String characterSet) |
void |
setCode(int code) |
void |
setConnection(OClientConnection connection) |
void |
setContent(String content) |
void |
setContentEncoding(String contentEncoding) |
void |
setContentType(String contentType) |
void |
setHeader(String iHeader)
Deprecated.
|
void |
setHeaders(String headers) |
void |
setJsonErrorResponse(boolean jsonErrorResponse) |
void |
setKeepAlive(boolean keepAlive) |
void |
setSameSiteCookie(boolean sameSiteCookie) |
void |
setSendStarted(boolean sendStarted) |
void |
setServerInfo(String serverInfo) |
void |
setSessionId(String sessionId) |
void |
setStaticEncoding(String contentEncoding) |
void |
setStreaming(boolean streaming) |
void |
writeContent(String iContent) |
void |
writeHeaders(String iContentType) |
void |
writeHeaders(String iContentType,
boolean iKeepAlive) |
void |
writeLine(String iContent) |
void |
writeRecord(ORecord iRecord) |
void |
writeRecord(ORecord iRecord,
String iFetchPlan,
String iFormat) |
void |
writeRecords(Object iRecords) |
void |
writeRecords(Object iRecords,
String iFetchPlan) |
void |
writeRecords(Object iRecords,
String iFetchPlan,
String iFormat,
String accept) |
void |
writeRecords(Object iRecords,
String iFetchPlan,
String iFormat,
String accept,
Map<String,Object> iAdditionalProperties) |
void |
writeRecords(Object iRecords,
String iFetchPlan,
String iFormat,
String accept,
Map<String,Object> iAdditionalProperties,
String mode) |
void |
writeResult(Object iResult) |
void |
writeResult(Object iResult,
String iFormat,
String iAccept) |
void |
writeResult(Object iResult,
String iFormat,
String iAccept,
Map<String,Object> iAdditionalProperties) |
void |
writeResult(Object iResult,
String iFormat,
String iAccept,
Map<String,Object> iAdditionalProperties,
String mode) |
abstract void |
writeStatus(int iStatus,
String iReason) |
public static final String JSON_FORMAT
public static final char[] URL_SEPARATOR
protected static final Charset utf8
public OHttpResponse(OutputStream iOutStream, String iHttpVersion, String[] iAdditionalHeaders, String iResponseCharSet, String iServerInfo, String iSessionId, String iCallbackFunction, boolean iKeepAlive, OClientConnection connection, OContextConfiguration contextConfiguration)
public abstract void send(int iCode, String iReason, String iContentType, Object iContent, String iHeaders) throws IOException
IOException
public abstract void writeStatus(int iStatus, String iReason) throws IOException
IOException
public void writeHeaders(String iContentType) throws IOException
IOException
public void writeHeaders(String iContentType, boolean iKeepAlive) throws IOException
IOException
public void writeLine(String iContent) throws IOException
IOException
public void writeContent(String iContent) throws IOException
IOException
public void writeResult(Object iResult) throws InterruptedException, IOException
InterruptedException
IOException
public void writeResult(Object iResult, String iFormat, String iAccept) throws InterruptedException, IOException
InterruptedException
IOException
public void writeResult(Object iResult, String iFormat, String iAccept, Map<String,Object> iAdditionalProperties) throws InterruptedException, IOException
InterruptedException
IOException
public void writeResult(Object iResult, String iFormat, String iAccept, Map<String,Object> iAdditionalProperties, String mode) throws InterruptedException, IOException
InterruptedException
IOException
public void writeRecords(Object iRecords) throws IOException
IOException
public void writeRecords(Object iRecords, String iFetchPlan) throws IOException
IOException
public void writeRecords(Object iRecords, String iFetchPlan, String iFormat, String accept) throws IOException
IOException
public void writeRecords(Object iRecords, String iFetchPlan, String iFormat, String accept, Map<String,Object> iAdditionalProperties) throws IOException
IOException
public void writeRecords(Object iRecords, String iFetchPlan, String iFormat, String accept, Map<String,Object> iAdditionalProperties, String mode) throws IOException
IOException
protected abstract void checkConnection() throws IOException
IOException
public void formatMultiValue(Iterator<?> iIterator, Writer buffer, String format) throws IOException
IOException
public void writeRecord(ORecord iRecord) throws IOException
IOException
public void writeRecord(ORecord iRecord, String iFetchPlan, String iFormat) throws IOException
IOException
public abstract void sendStream(int iCode, String iReason, String iContentType, InputStream iContent, long iSize) throws IOException
IOException
public abstract void sendStream(int iCode, String iReason, String iContentType, InputStream iContent, long iSize, String iFileName) throws IOException
IOException
public abstract void sendStream(int iCode, String iReason, String iContentType, InputStream iContent, long iSize, String iFileName, Map<String,String> additionalHeaders) throws IOException
IOException
public abstract void sendStream(int iCode, String iReason, String iContentType, String iFileName, OCallable<Void,OChunkedResponse> iWriter) throws IOException
IOException
public byte[] compress(String jsonStr)
@Deprecated public void setHeader(String iHeader)
public OutputStream getOutputStream()
public void flush() throws IOException
IOException
public String getContentType()
public void setContentType(String contentType)
public String getContentEncoding()
public void setContentEncoding(String contentEncoding)
public void setStaticEncoding(String contentEncoding)
public void setSessionId(String sessionId)
public String getContent()
public void setContent(String content)
public int getCode()
public void setCode(int code)
public void setJsonErrorResponse(boolean jsonErrorResponse)
public void setStreaming(boolean streaming)
public String getHttpVersion()
public OutputStream getOut()
public String getHeaders()
public void setHeaders(String headers)
public String[] getAdditionalHeaders()
public void setAdditionalHeaders(String[] additionalHeaders)
public String getCharacterSet()
public void setCharacterSet(String characterSet)
public String getServerInfo()
public void setServerInfo(String serverInfo)
public String getSessionId()
public String getCallbackFunction()
public void setCallbackFunction(String callbackFunction)
public String getStaticEncoding()
public boolean isSendStarted()
public void setSendStarted(boolean sendStarted)
public boolean isKeepAlive()
public void setKeepAlive(boolean keepAlive)
public boolean isJsonErrorResponse()
public OClientConnection getConnection()
public void setConnection(OClientConnection connection)
public boolean isStreaming()
public void setSameSiteCookie(boolean sameSiteCookie)
public boolean isSameSiteCookie()
public OContextConfiguration getContextConfiguration()
Copyright © 2009–2020 OrientDB. All rights reserved.