Interface HttpContextPreprocessor
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A preprocessor for a http context which is passed to a http handler.
- Since:
- 4.0
-
Method Summary
Modifier and TypeMethodDescriptionpreProcessContext(@NonNull String path, @NonNull HttpContext context) Called to preprocess the given context before passing it to the associated handler.
-
Method Details
-
preProcessContext
@Nullable @Nullable HttpContext preProcessContext(@NonNull @NonNull String path, @NonNull @NonNull HttpContext context) Called to preprocess the given context before passing it to the associated handler. If this processor returns null, it indicates that the http request processing should be stopped. The returned context is only passed to the associated handlers, further invocations will not receive a new context instance returned by this method.- Parameters:
path- the full path of the client request.context- the current context of the request.- Returns:
- the http context to pass to the handler, or null to drop the request execution.
- Throws:
NullPointerException- if the given path or context is null.
-