public class HttpMultiBodyDecoder extends Object
| 限定符和类型 | 类和说明 |
|---|---|
static class |
HttpMultiBodyDecoder.Header |
static interface |
HttpMultiBodyDecoder.MultiBodyHeaderKey
【
Content-Disposition: form-data; name="uploadFile"; filename=""
Content-Type: application/octet-stream
】
【
Content-Disposition: form-data; name="end"
】
|
static class |
HttpMultiBodyDecoder.Step |
| 构造器和说明 |
|---|
HttpMultiBodyDecoder() |
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
decode(HttpRequest request,
RequestLine firstLine,
byte[] bodyBytes,
String initboundary,
ChannelContext channelContext,
HttpConfig httpConfig) |
static HttpMultiBodyDecoder.Step |
parseBody(HttpMultiBodyDecoder.Header header,
HttpRequest request,
ByteBuffer buffer,
String boundary,
String endBoundary,
ChannelContext channelContext,
HttpConfig httpConfig) |
static void |
parseHeader(List<String> lines,
HttpMultiBodyDecoder.Header header,
ChannelContext channelContext)
【
Content-Disposition: form-data; name="uploadFile"; filename=""
Content-Type: application/octet-stream
】
【
Content-Disposition: form-data; name="end"
】
|
public static void decode(HttpRequest request, RequestLine firstLine, byte[] bodyBytes, String initboundary, ChannelContext channelContext, HttpConfig httpConfig) throws TioDecodeException
request - HttpRequestfirstLine - RequestLinebodyBytes - bodyBytesinitboundary - initboundarychannelContext - ChannelContexthttpConfig - HttpConfigTioDecodeExceptionpublic static HttpMultiBodyDecoder.Step parseBody(HttpMultiBodyDecoder.Header header, HttpRequest request, ByteBuffer buffer, String boundary, String endBoundary, ChannelContext channelContext, HttpConfig httpConfig) throws LengthOverflowException, TioDecodeException
header - Headerrequest - HttpRequestbuffer - ByteBufferboundary - boundaryendBoundary - endBoundarychannelContext - channelContexthttpConfig - HttpConfigLengthOverflowException - 异常TioDecodeExceptionpublic static void parseHeader(List<String> lines, HttpMultiBodyDecoder.Header header, ChannelContext channelContext) throws TioDecodeException
【 Content-Disposition: form-data; name="end" 】
lines - header - TioDecodeExceptionCopyright © 2023. All rights reserved.