FormatterContext Constructor (MediaTypeHeaderValue, Boolean)
[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Instantiates a new instance of a FormatterContext.
Namespace: System.Net.Http.Formatting
Assembly: System.Net.Http.Formatting (in System.Net.Http.Formatting.dll)
Syntax
'Declaration
Public Sub New ( _
contentType As MediaTypeHeaderValue, _
isRead As Boolean _
)
public FormatterContext(
MediaTypeHeaderValue contentType,
bool isRead
)
public:
FormatterContext(
MediaTypeHeaderValue^ contentType,
bool isRead
)
new :
contentType:MediaTypeHeaderValue *
isRead:bool -> FormatterContext
public function FormatterContext(
contentType : MediaTypeHeaderValue,
isRead : boolean
)
Parameters
- contentType
Type: System.Net.Http.Headers.MediaTypeHeaderValue
The MediaTypeHeaderValue to use in the absence of a request or response.
- isRead
Type: System.Boolean
Indicates if this is context is meant to select a formatter to read or to write.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.