java.lang.Object
org.eclipse.jetty.http.HttpField
- Direct Known Subclasses:
HostPortHttpField,HttpField.IntValueHttpField,HttpField.LongValueHttpField,PreEncodedHttpField
An HTTP Field
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic class -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final org.eclipse.jetty.util.QuotedStringTokenizerA constantQuotedStringTokenizerconfigured for quoting/tokenizing a singleparameteras defined by RFC9110static final org.eclipse.jetty.util.QuotedStringTokenizerA constantQuotedStringTokenizerconfigured for quoting/tokenizingparameterslists as defined by RFC9110 -
Constructor Summary
ConstructorsConstructorDescriptionHttpField(HttpHeader header, String value) HttpField(HttpHeader header, String name, String value) HttpField(HttpHeader header, HttpHeaderValue value) -
Method Summary
Modifier and TypeMethodDescriptionbooleanLook for a value in a possible multivalued fieldstatic booleanLook for a value in a possible multivalued fieldbooleanintlonggetName()getValue()static StringgetValueParameters(String valueParams, Map<String, String> parameters) Get field value parameters.String[]inthashCode()booleanbooleanisSameName(HttpField field) static StringstripParameters(String value) Get field value without parameters.toString()static StringvalueParameters(String value, Map<String, String> parameters)
-
Field Details
-
PARAMETER_TOKENIZER
public static final org.eclipse.jetty.util.QuotedStringTokenizer PARAMETER_TOKENIZERA constantQuotedStringTokenizerconfigured for quoting/tokenizingparameterslists as defined by RFC9110 -
NAME_VALUE_TOKENIZER
public static final org.eclipse.jetty.util.QuotedStringTokenizer NAME_VALUE_TOKENIZERA constantQuotedStringTokenizerconfigured for quoting/tokenizing a singleparameteras defined by RFC9110
-
-
Constructor Details
-
HttpField
-
HttpField
-
HttpField
-
HttpField
-
-
Method Details
-
getValueParameters
Get field value parameters. Some field values can have parameters. This method separates the value from the parameters and optionally populates a map with the parameters. For example:FieldName : Value ; param1=val1 ; param2=val2
- Parameters:
valueParams- The Field value, possibly with parameters.parameters- A map to populate with the parameters, or null- Returns:
- The value.
-
stripParameters
Get field value without parameters. Some field values can have parameters. This method separates the value from the parameters and optionally populates a map with the parameters. For example:FieldName : Value ; param1=val1 ; param2=val2
- Parameters:
value- The Field value, possibly with parameters.- Returns:
- The value.
-
valueParameters
-
contains
Look for a value in a possible multivalued field- Parameters:
search- Values to search for (case-insensitive)- Returns:
- True iff the value is contained in the field value entirely or as an element of a quoted comma separated list. List element parameters (eg qualities) are ignored, except if they are q=0, in which case the item itself is ignored.
-
contains
Look for a value in a possible multivalued field- Parameters:
value- The field value to search in.search- Values to search for (case-insensitive)- Returns:
- True iff the value is contained in the field value entirely or as an element of a quoted comma separated list. List element parameters (eg qualities) are ignored, except if they are q=0, in which case the item itself is ignored.
-
equals
-
getHeader
-
getIntValue
public int getIntValue() -
getLongValue
public long getLongValue() -
getLowerCaseName
-
getName
-
getValue
-
getValues
-
getValueList
-
hashCode
public int hashCode() -
isSameName
-
is
-
toString
-