Skip to main content
HttpExpectationHeaderValue class

Applies to Windows and Windows Phone

Represents a token for a particular server behavior required by the client that is used in the Expect HTTP header on an HTTP request.

Syntax


var httpExpectationHeaderValue = new Windows.Web.Http.Headers.HttpExpectationHeaderValue(string);
var httpExpectationHeaderValue = new Windows.Web.Http.Headers.HttpExpectationHeaderValue(string, string);

public sealed class HttpExpectationHeaderValue : IStringable

Public NotInheritable Class HttpExpectationHeaderValue
    Implements IStringable

public ref class HttpExpectationHeaderValue sealed : IStringable

Attributes

[ DualApiPartition()]
[ MarshalingBehavior(Agile)]
[ Threading(Both)]
[ Version(0x06030000)]

Members

The HttpExpectationHeaderValue class has these types of members:

Constructors

The HttpExpectationHeaderValue class has these constructors.

ConstructorDescription
HttpExpectationHeaderValue(String) Initializes a new instance of the HttpExpectationHeaderValue class with a name.
HttpExpectationHeaderValue(String, String) Initializes a new instance of the HttpExpectationHeaderValue class with a name and value for the name.

 

Methods

The HttpExpectationHeaderValue class has these methods. With C#, Visual Basic, and C++, it also inherits methods from the Object class.

MethodDescription
Parse Converts a string to an HttpExpectationHeaderValue instance.
ToString Returns a string that represents the current HttpExpectationHeaderValue object.
TryParse Determines whether a string is valid HttpCredentialsHeaderValue information.

 

Properties

The HttpExpectationHeaderValue class has these properties.

PropertyAccess typeDescription

Name

Read-onlyGets or sets a token that represents a name for a server behavior used in the Expect HTTP header.

Parameters

Read-onlyGets a set of parameters for a server behavior included in the Expect HTTP header.

Value

Read/writeGets or sets a value for a server behavior used in the Expect HTTP header.

 

Remarks

The HttpExpectationHeaderValue class is a token that represents a particular server behavior that is required by the client. The HttpExpectationHeaderValue is used in the Expect HTTP header on an HTTP request.

For example, 100-continue is a server behavior that the client might depend on and set using the HttpExpectationHeaderValue class.

The Expect property on the HttpRequestHeaderCollection returns an HttpExpectationHeaderValueCollection that contains HttpExpectationHeaderValue objects.

Requirements

Minimum supported client

Windows 8.1 [Windows Store apps, desktop apps]

Minimum supported server

Windows Server 2012 R2 [Windows Store apps, desktop apps]

Minimum supported phone

Windows Phone 8.1 [Windows Phone Silverlight 8.1 and Windows Runtime apps]

Namespace

Windows.Web.Http.Headers
Windows::Web::Http::Headers [C++]

Metadata

Windows.winmd

See also

Expect
HttpExpectationHeaderValueCollection
HttpRequestHeaderCollection
IStringable
Object