DefaultContentNegotiator.ComputeFormatterMatches Method (Type, HttpRequestMessage, IEnumerable<MediaTypeFormatter>)

 

Determines how well each formatter matches an HTTP request.

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

protected virtual Collection<MediaTypeFormatterMatch> ComputeFormatterMatches(
	Type type,
	HttpRequestMessage request,
	IEnumerable<MediaTypeFormatter> formatters
)

Parameters

type
Type: System.Type

The type to be serialized.

request
Type: System.Net.Http.HttpRequestMessage

The request.

formatters
Type: System.Collections.Generic.IEnumerable<MediaTypeFormatter>

The set of MediaTypeFormatter objects from which to choose.

Return Value

Type: System.Collections.ObjectModel.Collection<MediaTypeFormatterMatch>

Returns a collection of MediaTypeFormatterMatch objects that represent all of the matches.

Return to top
Show: