public static final class QueryStringDecoder.Builder extends Object
| Modifier and Type | Method and Description |
|---|---|
QueryStringDecoder |
build(String uri)
Create a decoder that will lazily decode the given URI with the settings configured in this builder.
|
QueryStringDecoder |
build(URI uri)
Create a decoder that will lazily decode the given URI with the settings configured in this builder.
|
QueryStringDecoder.Builder |
charset(Charset charset)
The charset to use for decoding percent escape sequences.
|
QueryStringDecoder.Builder |
hasPath(boolean hasPath)
true by default. |
QueryStringDecoder.Builder |
htmlQueryDecoding(boolean htmlQueryDecoding)
RFC 3986 (the URI standard) makes no mention of using '+' to encode a space in a URI query component.
|
QueryStringDecoder.Builder |
maxParams(int maxParams)
Maximum number of query parameters allowed, to mitigate HashDOS.
|
QueryStringDecoder.Builder |
semicolonIsNormalChar(boolean semicolonIsNormalChar)
false by default. |
public QueryStringDecoder.Builder hasPath(boolean hasPath)
true by default. When set to false, the input string only contains the query component of
the URI.hasPath - Whether the URI contains a pathpublic QueryStringDecoder.Builder maxParams(int maxParams)
maxParams - The maximum number of query parameterspublic QueryStringDecoder.Builder semicolonIsNormalChar(boolean semicolonIsNormalChar)
false by default. If set to true, instead of allowing query parameters to be separated by
semicolons, treat the semicolon as a normal character in a query value.semicolonIsNormalChar - Whether to treat semicolons as a normal characterpublic QueryStringDecoder.Builder charset(Charset charset)
HttpConstants.DEFAULT_CHARSET by default.charset - The charsetpublic QueryStringDecoder.Builder htmlQueryDecoding(boolean htmlQueryDecoding)
application/x-www-form-urlencoded serializer defined in the whatwg URL standard, which does use '+'
to encode a space instead of %20.
This flag controls whether the decoding should happen according to HTML rules, which decodes the '+' to a
space. The default is true.
htmlQueryDecoding - Whether to decode '+' to spacepublic QueryStringDecoder build(String uri)
uri - The URI in String formpublic QueryStringDecoder build(URI uri)
hasPath(boolean) has no effect when using this method.uri - The already parsed URICopyright © 2008–2025 The Netty Project. All rights reserved.