HttpContentDispositionHeaderValue HttpContentDispositionHeaderValue HttpContentDispositionHeaderValue HttpContentDispositionHeaderValue HttpContentDispositionHeaderValue Class

Definition

Represents the value of the Content-Disposition HTTP header on HTTP content in a request or a response.

public : sealed class HttpContentDispositionHeaderValue : IStringable
struct winrt::Windows::Web::Http::Headers::HttpContentDispositionHeaderValue : IStringable
public sealed class HttpContentDispositionHeaderValue : IStringable
Public NotInheritable Class HttpContentDispositionHeaderValue Implements IStringable
var httpContentDispositionHeaderValue = new httpContentDispositionHeaderValue(dispositionType);
Attributes

Windows 10 requirements

Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)

Examples

See the code example in HttpContentHeaderCollection class.

Remarks

The HttpContentDispositionHeaderValue class represents information in the Content-Disposition header on HTTP content sent in an HTTP request or received in an HTTP response.

The ContentDisposition property on the HttpContentHeaderCollection returns an HttpContentDispositionHeaderValue.

The Content-Disposition header is normally used for working with file uploads and downloads. The format differs from other headers in that it is a single header with a disposition type followed by a list of parameters, some of which are well defined.

This header is used in two different contexts:

Constructors

HttpContentDispositionHeaderValue(String) HttpContentDispositionHeaderValue(String) HttpContentDispositionHeaderValue(String) HttpContentDispositionHeaderValue(String) HttpContentDispositionHeaderValue(String)

Initializes a new instance of the HttpContentDispositionHeaderValue class with content-coding information for use in the Content-Disposition HTTP header.

Properties

DispositionType DispositionType DispositionType DispositionType DispositionType

Gets or sets the value of the disposition-type information in the Content-Disposition HTTP header.

FileName FileName FileName FileName FileName

Gets or sets the value of the filename-parm information in the Content-Disposition HTTP header for a single file.

FileNameStar FileNameStar FileNameStar FileNameStar FileNameStar

Gets or sets the value of the filename-parm characteristic in the Content-Disposition HTTP header for multiple files.

Name Name Name Name Name

Gets or sets the name for a content body part in the Content-Disposition HTTP header.

Parameters Parameters Parameters Parameters Parameters

Gets a set of parameters included in the Content-Disposition HTTP header.

Size Size Size Size Size

Gets or sets the approximate size, in bytes, of the file used in the Content-Disposition HTTP header.

Methods

Parse(String) Parse(String) Parse(String) Parse(String) Parse(String)

Converts a string to an HttpContentDispositionHeaderValue instance.

ToString() ToString() ToString() ToString() ToString()

Returns a string that represents the current HttpContentDispositionHeaderValue object.

TryParse(String, HttpContentDispositionHeaderValue) TryParse(String, HttpContentDispositionHeaderValue) TryParse(String, HttpContentDispositionHeaderValue) TryParse(String, HttpContentDispositionHeaderValue) TryParse(String, HttpContentDispositionHeaderValue)

Determines whether a string is valid HttpContentDispositionHeaderValue information.

See also