public abstract class HttpDecoderSpec<T extends HttpDecoderSpec<T>> extends Object implements java.util.function.Supplier<T>
HttpCodec
(or more precisely
the settings for the decoder)Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_INITIAL_BUFFER_SIZE |
static int |
DEFAULT_MAX_CHUNK_SIZE |
static int |
DEFAULT_MAX_HEADER_SIZE |
static int |
DEFAULT_MAX_INITIAL_LINE_LENGTH |
static boolean |
DEFAULT_VALIDATE_HEADERS |
protected int |
initialBufferSize |
protected int |
maxChunkSize |
protected int |
maxHeaderSize |
protected int |
maxInitialLineLength |
protected boolean |
validateHeaders |
Constructor and Description |
---|
HttpDecoderSpec() |
Modifier and Type | Method and Description |
---|---|
int |
initialBufferSize() |
T |
initialBufferSize(int value)
Configure the initial buffer size for HTTP request decoding.
|
int |
maxChunkSize() |
T |
maxChunkSize(int value)
Configure the maximum chunk size that can be decoded for the HTTP request.
|
int |
maxHeaderSize() |
T |
maxHeaderSize(int value)
Configure the maximum header size that can be decoded for the HTTP request.
|
int |
maxInitialLineLength() |
T |
maxInitialLineLength(int value)
Configure the maximum length that can be decoded for the HTTP request's initial
line.
|
boolean |
validateHeaders() |
T |
validateHeaders(boolean validate)
Configure whether or not to validate headers when decoding requests.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
get
public static final int DEFAULT_MAX_INITIAL_LINE_LENGTH
public static final int DEFAULT_MAX_HEADER_SIZE
public static final int DEFAULT_MAX_CHUNK_SIZE
public static final boolean DEFAULT_VALIDATE_HEADERS
public static final int DEFAULT_INITIAL_BUFFER_SIZE
protected int maxInitialLineLength
protected int maxHeaderSize
protected int maxChunkSize
protected boolean validateHeaders
protected int initialBufferSize
public T maxInitialLineLength(int value)
DEFAULT_MAX_INITIAL_LINE_LENGTH
.value
- the value for the maximum initial line length (strictly positive)public int maxInitialLineLength()
public T maxHeaderSize(int value)
DEFAULT_MAX_HEADER_SIZE
.value
- the value for the maximum header size (strictly positive)public int maxHeaderSize()
public T maxChunkSize(int value)
DEFAULT_MAX_CHUNK_SIZE
.value
- the value for the maximum chunk size (strictly positive)public int maxChunkSize()
public T validateHeaders(boolean validate)
validate
- true to validate headers, false otherwisepublic boolean validateHeaders()
public T initialBufferSize(int value)
DEFAULT_INITIAL_BUFFER_SIZE
.value
- the initial buffer size to use (strictly positive)public int initialBufferSize()