pekko/akka-docs/rst/scala/http/routing-dsl/directives/misc-directives/requestEntityEmpty.rst
2016-01-14 00:31:03 +01:00

26 lines
629 B
ReStructuredText

.. _-requestEntityEmpty-:
requestEntityEmpty
==================
Signature
---------
.. includecode2:: /../../akka-http/src/main/scala/akka/http/scaladsl/server/directives/MiscDirectives.scala
:snippet: requestEntityEmpty
Description
-----------
A filter that checks if the request entity is empty and only then passes processing to the inner route.
Otherwise, the request is rejected.
See also :ref:`-requestEntityPresent-` for the opposite effect.
Example
-------
.. includecode2:: ../../../../code/docs/http/scaladsl/server/directives/MiscDirectivesExamplesSpec.scala
:snippet: requestEntityEmptyPresent-example