HttpProvider Constructors
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
HttpProvider(ISerializer) |
Constructs a new HttpProvider. |
HttpProvider(HttpClientHandler, Boolean, ISerializer) |
Constructs a new HttpProvider. |
HttpProvider(HttpMessageHandler, Boolean, ISerializer) |
Constructs a new HttpProvider. |
HttpProvider(ISerializer)
Constructs a new HttpProvider.
public HttpProvider (Microsoft.Graph.ISerializer serializer = default);
new Microsoft.Graph.HttpProvider : Microsoft.Graph.ISerializer -> Microsoft.Graph.HttpProvider
Public Sub New (Optional serializer As ISerializer = Nothing)
Parameters
- serializer
- ISerializer
A serializer for serializing and deserializing JSON objects.
Applies to
HttpProvider(HttpClientHandler, Boolean, ISerializer)
Constructs a new HttpProvider.
public HttpProvider (System.Net.Http.HttpClientHandler httpClientHandler, bool disposeHandler, Microsoft.Graph.ISerializer serializer = default);
new Microsoft.Graph.HttpProvider : System.Net.Http.HttpClientHandler * bool * Microsoft.Graph.ISerializer -> Microsoft.Graph.HttpProvider
Public Sub New (httpClientHandler As HttpClientHandler, disposeHandler As Boolean, Optional serializer As ISerializer = Nothing)
Parameters
- httpClientHandler
- HttpClientHandler
An HTTP client handler to pass to the HttpClient for sending requests.
- disposeHandler
- Boolean
Whether or not to dispose the client handler on Dispose().
- serializer
- ISerializer
A serializer for serializing and deserializing JSON objects.
Remarks
By default, HttpProvider disables automatic redirects and handles redirects to preserve authentication headers. If providing an HttpClientHandler to the constructor and enabling automatic redirects this could cause issues with authentication over the redirect.
Applies to
HttpProvider(HttpMessageHandler, Boolean, ISerializer)
Constructs a new HttpProvider.
public HttpProvider (System.Net.Http.HttpMessageHandler httpMessageHandler, bool disposeHandler, Microsoft.Graph.ISerializer serializer);
new Microsoft.Graph.HttpProvider : System.Net.Http.HttpMessageHandler * bool * Microsoft.Graph.ISerializer -> Microsoft.Graph.HttpProvider
Public Sub New (httpMessageHandler As HttpMessageHandler, disposeHandler As Boolean, serializer As ISerializer)
Parameters
- httpMessageHandler
- HttpMessageHandler
An HTTP message handler to pass to the HttpClient for sending requests.
- disposeHandler
- Boolean
Whether or not to dispose the client handler on Dispose().
- serializer
- ISerializer
A serializer for serializing and deserializing JSON objects.