HttpResponseMessage.StatusCode 属性
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
获取或设置 HTTP 响应的状态代码。
public:
property HttpStatusCode StatusCode { HttpStatusCode get(); void set(HttpStatusCode value); };
HttpStatusCode StatusCode();
void StatusCode(HttpStatusCode value);
public HttpStatusCode StatusCode { get; set; }
var httpStatusCode = httpResponseMessage.statusCode;
httpResponseMessage.statusCode = httpStatusCode;
Public Property StatusCode As HttpStatusCode
属性值
HTTP 响应的状态代码。