Class MediaTypeRegistration
java.lang.Object
io.vertx.rxjava3.openapi.mediatype.MediaTypeRegistration
- All Implemented Interfaces:
io.vertx.lang.rx.RxDelegate
A MediaTypeRegistration is used to register mediatypes to the openapi mediatype registry. It consists of a predicate
that checks if a media type can be handled by the created content analysers.
NOTE: This class has been automatically generated from the original non RX-ified interface using Vert.x codegen.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final io.vertx.lang.rx.TypeArg<MediaTypeRegistration> static final MediaTypeRegistrationstatic final MediaTypeRegistrationstatic final MediaTypeRegistrationstatic final MediaTypeRegistrationstatic final MediaTypeRegistrationstatic final MediaTypeRegistration -
Constructor Summary
ConstructorsConstructorDescriptionMediaTypeRegistration(MediaTypeRegistration delegate) MediaTypeRegistration(Object delegate) -
Method Summary
Modifier and TypeMethodDescriptionbooleanChecks if this registration can handle the given media type.createContentAnalyser(String contentType, Buffer content, ValidationContext context) Creates a newContentAnalyser.booleaninthashCode()static MediaTypeRegistrationThis method is intended for reporting of supported media types in the system.toString()
-
Field Details
-
__TYPE_ARG
-
APPLICATION_JSON
-
MULTIPART_FORM_DATA
-
TEXT_PLAIN
-
APPLICATION_OCTET_STREAM
-
APPLICATION_X_WWW_FORM_URL_ENCODED
-
VENDOR_SPECIFIC_JSON
-
-
Constructor Details
-
MediaTypeRegistration
-
MediaTypeRegistration
-
-
Method Details
-
toString
-
equals
-
hashCode
-
getDelegate
- Specified by:
getDelegatein interfaceio.vertx.lang.rx.RxDelegate
-
createContentAnalyser
public ContentAnalyser createContentAnalyser(String contentType, Buffer content, ValidationContext context) Creates a newContentAnalyser. This is required, becauseContentAnalysercould be stateful.- Parameters:
contentType- The raw content type from the http headers.content- The content of the request or response.context- Whether the analyser is for a request or response.- Returns:
- A fresh content analyser instance.
-
canHandle
Checks if this registration can handle the given media type. This method is intended to be used by the MediaTypeRegistry.- Parameters:
mediaType- The media type to check- Returns:
- true if the mediatype can be handled, false otherwise
-
supportedTypes
-
newInstance
-