Package discord4j.rest.http
Interface ExchangeStrategies
-
public interface ExchangeStrategiesDefines the strategies to request and response body conversion.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classExchangeStrategies.BuilderA mutable builder for creating anExchangeStrategies
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description static ExchangeStrategiesjackson(ObjectMapper mapper)Return anExchangeStrategiesusing the defaults for processing JSON requests using Jackson.List<ReaderStrategy<?>>readers()Retrieve the list of reader strategies to convert a response body.List<WriterStrategy<?>>writers()Retrieve the list of writer strategies to convert a request body.
-
-
-
Method Detail
-
writers
List<WriterStrategy<?>> writers()
Retrieve the list of writer strategies to convert a request body.- Returns:
- a list of writer strategies
-
readers
List<ReaderStrategy<?>> readers()
Retrieve the list of reader strategies to convert a response body.- Returns:
- a list of reader strategies
-
jackson
static ExchangeStrategies jackson(ObjectMapper mapper)
Return anExchangeStrategiesusing the defaults for processing JSON requests using Jackson.- Parameters:
mapper- the Jackson object mapper- Returns:
- the built strategies
-
-