Package io.undertow.attribute
Class QueryStringAttribute
- java.lang.Object
-
- io.undertow.attribute.QueryStringAttribute
-
- All Implemented Interfaces:
ExchangeAttribute
public class QueryStringAttribute extends java.lang.Object implements ExchangeAttribute
The query string- Author:
- Stuart Douglas
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
QueryStringAttribute.Builder
-
Field Summary
Fields Modifier and Type Field Description static ExchangeAttribute
BARE_INSTANCE
static java.lang.String
BARE_QUERY_STRING
static ExchangeAttribute
INSTANCE
static java.lang.String
QUERY_STRING
static java.lang.String
QUERY_STRING_SHORT
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
readAttribute(HttpServerExchange exchange)
Resolve the attribute from the HTTP server exchange.java.lang.String
toString()
void
writeAttribute(HttpServerExchange exchange, java.lang.String newValue)
Sets a new value for the attribute.
-
-
-
Field Detail
-
QUERY_STRING_SHORT
public static final java.lang.String QUERY_STRING_SHORT
- See Also:
- Constant Field Values
-
QUERY_STRING
public static final java.lang.String QUERY_STRING
- See Also:
- Constant Field Values
-
BARE_QUERY_STRING
public static final java.lang.String BARE_QUERY_STRING
- See Also:
- Constant Field Values
-
INSTANCE
public static final ExchangeAttribute INSTANCE
-
BARE_INSTANCE
public static final ExchangeAttribute BARE_INSTANCE
-
-
Method Detail
-
readAttribute
public java.lang.String readAttribute(HttpServerExchange exchange)
Description copied from interface:ExchangeAttribute
Resolve the attribute from the HTTP server exchange. This may return null if the attribute is not present.- Specified by:
readAttribute
in interfaceExchangeAttribute
- Parameters:
exchange
- The exchange- Returns:
- The attribute
-
writeAttribute
public void writeAttribute(HttpServerExchange exchange, java.lang.String newValue) throws ReadOnlyAttributeException
Description copied from interface:ExchangeAttribute
Sets a new value for the attribute. Not all attributes are writable.- Specified by:
writeAttribute
in interfaceExchangeAttribute
- Parameters:
exchange
- The exchangenewValue
- The new value for the attribute- Throws:
ReadOnlyAttributeException
- when attribute cannot be written
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-