public final class ProblemRoute extends Object
| Modifier and Type | Method and Description |
|---|---|
static Route |
problemHandling()
Produces a
route that dispatches on the content type and
recognises application/problem+json as well as application/x-problem+json and
application/x.problem+json as problems and propagates
them. |
static Route |
problemHandling(Route fallback)
Produces a
route that dispatches on the content type and
recognises application/problem+json as well as application/x-problem+json and
application/x.problem+json as problems and propagates
them. |
static Route |
problemHandling(org.zalando.fauxpas.ThrowingConsumer<org.zalando.problem.Exceptional,? extends Exception> consumer)
Produces a
route that dispatches on the content type and
recognises application/problem+json as well as application/x-problem+json and
application/x.problem+json as problems and handles them given the supplied consumer. |
static Route |
problemHandling(org.zalando.fauxpas.ThrowingConsumer<org.zalando.problem.Exceptional,? extends Exception> consumer,
Route fallback)
Produces a
route that dispatches on the content type and
recognises application/problem+json as well as application/x-problem+json and
application/x.problem+json as problems and handles them given the supplied consumer. |
public static Route problemHandling()
route that dispatches on the content type and
recognises application/problem+json as well as application/x-problem+json and
application/x.problem+json as problems and propagates
them.problemHandling(ThrowingConsumer),
Exceptional.propagate()public static Route problemHandling(org.zalando.fauxpas.ThrowingConsumer<org.zalando.problem.Exceptional,? extends Exception> consumer)
route that dispatches on the content type and
recognises application/problem+json as well as application/x-problem+json and
application/x.problem+json as problems and handles them given the supplied consumer.consumer - the exception handlerpublic static Route problemHandling(Route fallback)
route that dispatches on the content type and
recognises application/problem+json as well as application/x-problem+json and
application/x.problem+json as problems and propagates
them. The given fallback will be used if none of the mentioned content types matches.fallback - the fallback routepublic static Route problemHandling(org.zalando.fauxpas.ThrowingConsumer<org.zalando.problem.Exceptional,? extends Exception> consumer, Route fallback)
route that dispatches on the content type and
recognises application/problem+json as well as application/x-problem+json and
application/x.problem+json as problems and handles them given the supplied consumer.
The given fallback will be used if none of the mentioned content types matches.consumer - the exception handlerfallback - the fallback routeCopyright © 2015–2018 Zalando SE. All rights reserved.