public final class RedirectPolicy extends Object implements HttpPipelinePolicy
Constructor and Description |
---|
RedirectPolicy()
Creates
RedirectPolicy with default DefaultRedirectStrategy as RedirectStrategy and
uses the redirect status response code (301, 302, 307, 308) to determine if this request should be redirected. |
RedirectPolicy(RedirectStrategy redirectStrategy)
Creates
RedirectPolicy with the provided redirectStrategy as RedirectStrategy
to determine if this request should be redirected. |
Modifier and Type | Method and Description |
---|---|
Mono<HttpResponse> |
process(HttpPipelineCallContext context,
HttpPipelineNextPolicy next)
Processes provided request context and invokes the next policy.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getPipelinePosition
public RedirectPolicy()
RedirectPolicy
with default DefaultRedirectStrategy
as RedirectStrategy
and
uses the redirect status response code (301, 302, 307, 308) to determine if this request should be redirected.public RedirectPolicy(RedirectStrategy redirectStrategy)
RedirectPolicy
with the provided redirectStrategy
as RedirectStrategy
to determine if this request should be redirected.redirectStrategy
- The RedirectStrategy
used for redirection.NullPointerException
- When redirectStrategy
is null
.public Mono<HttpResponse> process(HttpPipelineCallContext context, HttpPipelineNextPolicy next)
HttpPipelinePolicy
process
in interface HttpPipelinePolicy
context
- The request context.next
- The next policy to invoke.Copyright © 2021 Microsoft Corporation. All rights reserved.