HttpResponseMessage<T> Constructor (T, HttpStatusCode)
[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Initializes a new instance of the <see cref="T:System.Net.Http.HttpResponseMessage`1" /> class.
Namespace: System.Net.Http
Assembly: System.Net.Http.Formatting (in System.Net.Http.Formatting.dll)
Syntax
'Declaration
Public Sub New ( _
value As T, _
statusCode As HttpStatusCode _
)
public HttpResponseMessage(
T value,
HttpStatusCode statusCode
)
public:
HttpResponseMessage(
T value,
HttpStatusCode statusCode
)
new :
value:'T *
statusCode:HttpStatusCode -> HttpResponseMessage
public function HttpResponseMessage(
value : T,
statusCode : HttpStatusCode
)
Parameters
- value
Type: T
The value to use as the content of this new instance.
- statusCode
Type: System.Net.HttpStatusCode
The HttpStatusCode to use for this response.
.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.