Share via


RequestHeaderMapping Constructor (String, String, StringComparison, Boolean, )

Initializes a new instance of the RequestHeaderMapping class.

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

Syntax

'Declaration
Public Sub New ( _
    headerName As String, _
    headerValue As String, _
    valueComparison As StringComparison, _
    isValueSubstring As Boolean, _
    mediaType As MediaTypeHeaderValue _
)
'Usage
Dim headerName As String
Dim headerValue As String
Dim valueComparison As StringComparison
Dim isValueSubstring As Boolean
Dim mediaType As MediaTypeHeaderValue

Dim instance As New RequestHeaderMapping(headerName, _
    headerValue, valueComparison, isValueSubstring, _
    mediaType)
public RequestHeaderMapping(
    string headerName,
    string headerValue,
    StringComparison valueComparison,
    bool isValueSubstring,
    MediaTypeHeaderValue mediaType
)
public:
RequestHeaderMapping(
    String^ headerName, 
    String^ headerValue, 
    StringComparison valueComparison, 
    bool isValueSubstring, 
    MediaTypeHeaderValue^ mediaType
)
new : 
        headerName:string * 
        headerValue:string * 
        valueComparison:StringComparison * 
        isValueSubstring:bool * 
        mediaType:MediaTypeHeaderValue -> RequestHeaderMapping
public function RequestHeaderMapping(
    headerName : String, 
    headerValue : String, 
    valueComparison : StringComparison, 
    isValueSubstring : boolean, 
    mediaType : MediaTypeHeaderValue
)

Parameters

  • isValueSubstring
    Type: System.Boolean
    if set to true then headerValue is considered a match if it matches a substring of the actual header value.
  • mediaType
    Type: MediaTypeHeaderValue
    The MediaTypeHeaderValue to use if headerName and headerValue is considered a match.

See Also

Reference

RequestHeaderMapping Class

RequestHeaderMapping Overload

System.Net.Http.Formatting Namespace