Jaa


HttpMethod Class

Definition

Retrieves standard HTTP methods such as GET and POST and creates new HTTP methods.

public ref class HttpMethod sealed : IStringable
/// [Windows.Foundation.Metadata.Activatable(Windows.Web.Http.IHttpMethodFactory, 65536, Windows.Foundation.UniversalApiContract)]
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class HttpMethod final : IStringable
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
/// [Windows.Foundation.Metadata.Activatable(Windows.Web.Http.IHttpMethodFactory, 65536, "Windows.Foundation.UniversalApiContract")]
class HttpMethod final : IStringable
[Windows.Foundation.Metadata.Activatable(typeof(Windows.Web.Http.IHttpMethodFactory), 65536, typeof(Windows.Foundation.UniversalApiContract))]
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class HttpMethod : IStringable
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
[Windows.Foundation.Metadata.Activatable(typeof(Windows.Web.Http.IHttpMethodFactory), 65536, "Windows.Foundation.UniversalApiContract")]
public sealed class HttpMethod : IStringable
function HttpMethod(method)
Public NotInheritable Class HttpMethod
Implements IStringable
Inheritance
Object Platform::Object IInspectable HttpMethod
Attributes
Implements

Windows requirements

Device family
Windows 10 (introduced in 10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced in v1.0)

Remarks

The most common use of HttpMethod is to get a standard HTTP method (verb) from a property on this class. However, if an app needs a different value for the HTTP method, the HttpMethod constructor initializes a new instance of the HttpMethod with an HTTP method that the app developer specifies.

Constructors

HttpMethod(String)

Initializes a new instance of the HttpMethod class with a specific HTTP method.

Properties

Delete

Gets the HTTP DELETE method.

Get

Gets the HTTP GET method.

Head

Gets the HTTP HEAD method.

Method

Gets the HTTP method.

Options

Gets the HTTP OPTIONS method.

Patch

Gets the HTTP PATCH method,

Post

Gets the HTTP POST method.

Put

Gets the HTTP PUT method.

Methods

ToString()

Returns a string that represents the current HttpMethod object.

Applies to

See also