@Documented @Target(value={PARAMETER,TYPE}) @Retention(value=RUNTIME) @Inherited public @interface Request
Identifies an interface to use to interact with HTTP parts of an HTTP request through a bean.
Can be used in the following locations:
The return types of the getters must be the supported parameter types for the HTTP-part annotation used.
Schema-based serialization and parsing is allowed just as if used as individual parameter types.
Modifier and Type | Optional Element and Description |
---|---|
Class<? extends HttpPartParser> |
parser
Specifies the
HttpPartParser class used for parsing strings to values. |
Class<? extends HttpPartSerializer> |
serializer
Specifies the
HttpPartSerializer class used for serializing values to strings. |
public abstract Class<? extends HttpPartSerializer> serializer
HttpPartSerializer
class used for serializing values to strings.
Overrides for this part the part serializer defined on the REST client which by default is OpenApiSerializer
.
public abstract Class<? extends HttpPartParser> parser
HttpPartParser
class used for parsing strings to values.
Overrides for this part the part parser defined on the REST resource which by default is OpenApiParser
.
Copyright © 2016–2020 The Apache Software Foundation. All rights reserved.