Package org.jdrupes.httpcodec.types
Class ParameterizedValue<U>
java.lang.Object
org.jdrupes.httpcodec.types.ParameterizedValue<U>
- Type Parameters:
U- the type of the unparameterized value
- Direct Known Subclasses:
MediaBase
Represents a parameterized value
such as
value; param1=value1; param2=value2.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classParameterizedValue.Builder<R extends ParameterizedValue<T>,T> A builder for the (immutable) parameterized type.static classExtendsParameterizedValue.ParamValueConverterBaseto a realization ofConverter<ParameterizedValue<T>>.static classA base class for converters for parameterized values. -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionParameterizedValue(U value) Creates a new object with the given value and no parameters.ParameterizedValue(U value, Map<String, String> parameters) Creates a new object with the given value and parameters. -
Method Summary
Modifier and TypeMethodDescriptionstatic <T> ParameterizedValue.Builder<ParameterizedValue<T>,T> builder()Creates a new builder for a parameterized value.booleaninthashCode()Return the value of the parameter with the given name.Returns the parameters.toString()value()Returns the value.
-
Field Details
-
WEIGHT_COMPARATOR
-
-
Constructor Details
-
ParameterizedValue
Creates a new object with the given value and parameters.- Parameters:
value- the valueparameters- the parameters
-
ParameterizedValue
Creates a new object with the given value and no parameters.- Parameters:
value- the value
-
-
Method Details
-
value
Returns the value.- Returns:
- the value
-
parameters
Returns the parameters.- Returns:
- the parameters as unmodifiable map
-
parameter
Return the value of the parameter with the given name.- Parameters:
name- the name- Returns:
- the value or
nullif there is no parameter with this name
-
builder
Creates a new builder for a parameterized value.- Returns:
- the builder
-
hashCode
-
equals
-
toString
-