pekko/akka-docs/rst/java/http/routing-dsl/directives/coding-directives/responseEncodingAccepted.rst

14 lines
435 B
ReStructuredText

.. _-responseEncodingAccepted-java-:
responseEncodingAccepted
========================
Description
-----------
Passes the request to the inner route if the request accepts the argument encoding. Otherwise, rejects the request with an ``UnacceptedResponseEncodingRejection(encoding)``.
Example
-------
.. includecode:: ../../../../code/docs/http/javadsl/server/directives/CodingDirectivesExamplesTest.java#responseEncodingAccepted