Partager via


HttpClientHandlerExtensions.SupportsAllowAutoRedirect Method

Determines whether the HTTP client handler supports following redirection responses.

Namespace:  System.Net.Http
Assembly:  System.Net.Http.Extensions (in System.Net.Http.Extensions.dll)

Syntax

'Declaration
<ExtensionAttribute> _
Public Shared Function SupportsAllowAutoRedirect ( _
    handler As HttpClientHandler _
) As Boolean
'Usage
Dim handler As HttpClientHandler 
Dim returnValue As Boolean 

returnValue = handler.SupportsAllowAutoRedirect()
public static bool SupportsAllowAutoRedirect(
    this HttpClientHandler handler
)
[ExtensionAttribute]
public:
static bool SupportsAllowAutoRedirect(
    HttpClientHandler^ handler
)
static member SupportsAllowAutoRedirect : 
        handler:HttpClientHandler -> bool
public static function SupportsAllowAutoRedirect(
    handler : HttpClientHandler
) : boolean

Parameters

Return Value

Type: System.Boolean
true if the handler supports following redirection responses; otherwise, false.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type HttpClientHandler. When you use instance method syntax to call this method, omit the first parameter. For more information, see https://msdn.microsoft.com/en-us/library/bb384936(v=vs.118) or https://msdn.microsoft.com/en-us/library/bb383977(v=vs.118).

See Also

Reference

HttpClientHandlerExtensions Class

System.Net.Http Namespace