Package org.jdrupes.httpcodec.types
Class MediaBase.MediaTypePairConverter
java.lang.Object
org.jdrupes.httpcodec.types.MediaBase.MediaTypePairConverter
- All Implemented Interfaces:
Converter<MediaBase.MediaTypePair>
- Enclosing class:
- MediaBase
public static class MediaBase.MediaTypePairConverter
extends Object
implements Converter<MediaBase.MediaTypePair>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the representation of this value in a header field.fromFieldValue(String text) Parses the given text and returns the parsed value.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.jdrupes.httpcodec.types.Converter
asHeaderField
-
Constructor Details
-
MediaTypePairConverter
public MediaTypePairConverter()
-
-
Method Details
-
asFieldValue
Description copied from interface:ConverterReturns the representation of this value in a header field.- Specified by:
asFieldValuein interfaceConverter<MediaBase.MediaTypePair>- Parameters:
value- the value to be converted- Returns:
- the representation
-
fromFieldValue
Description copied from interface:ConverterParses the given text and returns the parsed value.- Specified by:
fromFieldValuein interfaceConverter<MediaBase.MediaTypePair>- Parameters:
text- the value from the header field- Returns:
- the parsed value
- Throws:
ParseException- if the value cannot be parsed
-