-
- All Implemented Interfaces:
public final class HttpResult
-
-
Field Summary
Fields Modifier and Type Field Description private ByteArraybufferprivate Integercodeprivate Stringmsgprivate StringcontentTypeprivate IntegercontentLengthprivate Map<String, List<String>>headersprivate Exceptionexceptionprivate BooleanneedDecodeprivate final BooleanOKprivate final StringerrorMessageprivate final CharsetcontentCharsetprivate final ByteArrayvalueBytesprivate final StringvalueTextprivate final Stringurl
-
Constructor Summary
Constructors Constructor Description HttpResult(String url)
-
Method Summary
Modifier and Type Method Description final ByteArraygetBuffer()final UnitsetBuffer(ByteArray buffer)final IntegergetCode()final UnitsetCode(Integer code)final StringgetMsg()final UnitsetMsg(String msg)final StringgetContentType()final UnitsetContentType(String contentType)final IntegergetContentLength()final UnitsetContentLength(Integer contentLength)final Map<String, List<String>>getHeaders()final UnitsetHeaders(Map<String, List<String>> headers)final ExceptiongetException()final UnitsetException(Exception exception)final BooleangetNeedDecode()final UnitsetNeedDecode(Boolean needDecode)final BooleangetOK()final StringgetErrorMessage()final CharsetgetContentCharset()final ByteArraygetValueBytes()final StringgetValueText()final StringgetUrl()final StringbufferToString(Charset charset)final <T extends Any> TtextTo(Function1<String, T> block)final YsonArrayysonArray()final YsonObjectysonObject()final BooleansaveTo(File file)-
-
Constructor Detail
-
HttpResult
HttpResult(String url)
-
-
Method Detail
-
getContentType
final String getContentType()
-
setContentType
final Unit setContentType(String contentType)
-
getContentLength
final Integer getContentLength()
-
setContentLength
final Unit setContentLength(Integer contentLength)
-
getHeaders
final Map<String, List<String>> getHeaders()
-
getException
final Exception getException()
-
setException
final Unit setException(Exception exception)
-
getNeedDecode
final Boolean getNeedDecode()
-
setNeedDecode
final Unit setNeedDecode(Boolean needDecode)
-
getErrorMessage
final String getErrorMessage()
-
getContentCharset
final Charset getContentCharset()
-
getValueBytes
final ByteArray getValueBytes()
-
getValueText
final String getValueText()
-
bufferToString
final String bufferToString(Charset charset)
-
ysonObject
final YsonObject ysonObject()
-
-
-
-