HttpContentCodingHeaderValueCollection HttpContentCodingHeaderValueCollection HttpContentCodingHeaderValueCollection HttpContentCodingHeaderValueCollection Class

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

Syntax

Declaration

public sealed class HttpContentCodingHeaderValueCollectionpublic sealed class HttpContentCodingHeaderValueCollectionPublic NotInheritable Class HttpContentCodingHeaderValueCollectionpublic sealed class HttpContentCodingHeaderValueCollection

Remarks

The HttpContentCodingHeaderValueCollection class represents the value of the Content-Encoding HTTP header on HTTP content sent in an HTTP request or received in an HTTP response.

The HttpContentCodingHeaderValueCollection provides a collection container for instances of the HttpConnectionOptionHeaderValue class objects used for content encoding information in the Content-Encoding HTTP header.

The ContentEncoding property on the HttpContentHeaderCollection returns an HttpContentCodingHeaderValueCollection.

Collection member lists

For JavaScript, HttpContentCodingHeaderValueCollection has the members shown in the member lists. In addition, HttpContentCodingHeaderValueCollection supports members of Array.prototype and using an index to access items.

Enumerating the collection in C# or Microsoft Visual Basic

You can iterate through an HttpContentCodingHeaderValueCollection object in C# or Microsoft Visual Basic. In many cases, such as using foreach syntax, the compiler does this casting for you and you won't need to cast to IEnumerable<HttpContentCodingHeaderValue> explicitly. If you do need to cast explicitly, for example if you want to call GetEnumerator, cast the collection object to IEnumerable<T> with an HttpContentCodingHeaderValue constraint.

Properties summary

Gets the number of HttpContentCodingHeaderValue objects in the collection.

Methods summary

Adds a new HttpContentCodingHeaderValue item to the end of the collection.

Removes all objects from the collection.

Retrieves an iterator to the first HttpContentCodingHeaderValue item in the collection.

Returns the HttpContentCodingHeaderValue at the specified index in the collection.

Retrieves the HttpContentCodingHeaderValue items that start at the specified index in the collection.

Returns an immutable view of the HttpContentCodingHeaderValueCollection.

Retrieves the index of an HttpContentCodingHeaderValue in the collection.

Inserts an HttpContentCodingHeaderValue into the collection at the specified index.

Parses and adds an entry to the HttpContentCodingHeaderValueCollection.

Removes the entry at the specified index from the HttpContentCodingHeaderValueCollection.

Removes the last HttpContentCodingHeaderValue item from the collection.

Replaces all the HttpContentCodingHeaderValue items in the collection with the specified HttpContentCodingHeaderValue items.

Sets the HttpContentCodingHeaderValue at the specified index in the collection.

Returns a string that represents the current HttpContentCodingHeaderValueCollection object.

Tries to parse and add the specified item to the HttpContentCodingHeaderValueCollection.

Properties

Methods

  • Append(HttpContentCodingHeaderValue)
    Append(HttpContentCodingHeaderValue)
    Append(HttpContentCodingHeaderValue)
    Append(HttpContentCodingHeaderValue)

    Adds a new HttpContentCodingHeaderValue item to the end of the collection.

    public void Append(HttpContentCodingHeaderValue value)public void Append(HttpContentCodingHeaderValue value)Public Function Append(value As HttpContentCodingHeaderValue) As voidpublic void Append(HttpContentCodingHeaderValue value)

    Parameters

  • Clear()
    Clear()
    Clear()
    Clear()

    Removes all objects from the collection.

    public void Clear()public void Clear()Public Function Clear() As voidpublic void Clear()
  • First()
    First()
    First()
    First()

    Retrieves an iterator to the first HttpContentCodingHeaderValue item in the collection.

    public IIterator<HttpContentCodingHeaderValue> First()public IIterator<HttpContentCodingHeaderValue> First()Public Function First() As IIterator( Of HttpContentCodingHeaderValue )public IIterator<HttpContentCodingHeaderValue> First()

    Returns

  • GetAt(UInt32)
    GetAt(UInt32)
    GetAt(UInt32)
    GetAt(UInt32)

    Returns the HttpContentCodingHeaderValue at the specified index in the collection.

    public HttpContentCodingHeaderValue GetAt(UInt32 index)public HttpContentCodingHeaderValue GetAt(UInt32 index)Public Function GetAt(index As UInt32) As HttpContentCodingHeaderValuepublic HttpContentCodingHeaderValue GetAt(UInt32 index)

    Parameters

    Returns

  • GetMany(UInt32, HttpContentCodingHeaderValue[])
    GetMany(UInt32, HttpContentCodingHeaderValue[])
    GetMany(UInt32, HttpContentCodingHeaderValue[])
    GetMany(UInt32, HttpContentCodingHeaderValue[])

    Retrieves the HttpContentCodingHeaderValue items that start at the specified index in the collection.

    public uint GetMany(UInt32 startIndex, HttpContentCodingHeaderValue[] items)public uint GetMany(UInt32 startIndex, HttpContentCodingHeaderValue[] items)Public Function GetMany(startIndex As UInt32, items As HttpContentCodingHeaderValue[]) As uintpublic uint GetMany(UInt32 startIndex, HttpContentCodingHeaderValue[] items)

    Parameters

    Returns

  • GetView()
    GetView()
    GetView()
    GetView()

    Returns an immutable view of the HttpContentCodingHeaderValueCollection.

    public IVectorView<HttpContentCodingHeaderValue> GetView()public IVectorView<HttpContentCodingHeaderValue> GetView()Public Function GetView() As IVectorView( Of HttpContentCodingHeaderValue )public IVectorView<HttpContentCodingHeaderValue> GetView()

    Returns

  • IndexOf(HttpContentCodingHeaderValue, UInt32)
    IndexOf(HttpContentCodingHeaderValue, UInt32)
    IndexOf(HttpContentCodingHeaderValue, UInt32)
    IndexOf(HttpContentCodingHeaderValue, UInt32)

    Retrieves the index of an HttpContentCodingHeaderValue in the collection.

    public bool IndexOf(HttpContentCodingHeaderValue value, UInt32 index)public bool IndexOf(HttpContentCodingHeaderValue value, UInt32 index)Public Function IndexOf(value As HttpContentCodingHeaderValue, index As UInt32) As boolpublic bool IndexOf(HttpContentCodingHeaderValue value, UInt32 index)

    Parameters

    Returns

  • InsertAt(UInt32, HttpContentCodingHeaderValue)
    InsertAt(UInt32, HttpContentCodingHeaderValue)
    InsertAt(UInt32, HttpContentCodingHeaderValue)
    InsertAt(UInt32, HttpContentCodingHeaderValue)

    Inserts an HttpContentCodingHeaderValue into the collection at the specified index.

    public void InsertAt(UInt32 index, HttpContentCodingHeaderValue value)public void InsertAt(UInt32 index, HttpContentCodingHeaderValue value)Public Function InsertAt(index As UInt32, value As HttpContentCodingHeaderValue) As voidpublic void InsertAt(UInt32 index, HttpContentCodingHeaderValue value)

    Parameters

  • ParseAdd(String)
    ParseAdd(String)
    ParseAdd(String)
    ParseAdd(String)

    Parses and adds an entry to the HttpContentCodingHeaderValueCollection.

    public void ParseAdd(String input)public void ParseAdd(String input)Public Function ParseAdd(input As String) As voidpublic void ParseAdd(String input)

    Parameters

    • input
      System.String
      System.String
      System.String
      System.String

      The entry to add.

  • RemoveAt(UInt32)
    RemoveAt(UInt32)
    RemoveAt(UInt32)
    RemoveAt(UInt32)

    Removes the entry at the specified index from the HttpContentCodingHeaderValueCollection.

    public void RemoveAt(UInt32 index)public void RemoveAt(UInt32 index)Public Function RemoveAt(index As UInt32) As voidpublic void RemoveAt(UInt32 index)

    Parameters

    • index
      System.UInt32
      System.UInt32
      System.UInt32
      System.UInt32

      The index of the entry to remove.

  • RemoveAtEnd()
    RemoveAtEnd()
    RemoveAtEnd()
    RemoveAtEnd()

    Removes the last HttpContentCodingHeaderValue item from the collection.

    public void RemoveAtEnd()public void RemoveAtEnd()Public Function RemoveAtEnd() As voidpublic void RemoveAtEnd()
  • ReplaceAll(HttpContentCodingHeaderValue[])
    ReplaceAll(HttpContentCodingHeaderValue[])
    ReplaceAll(HttpContentCodingHeaderValue[])
    ReplaceAll(HttpContentCodingHeaderValue[])

    Replaces all the HttpContentCodingHeaderValue items in the collection with the specified HttpContentCodingHeaderValue items.

    public void ReplaceAll(HttpContentCodingHeaderValue[] items)public void ReplaceAll(HttpContentCodingHeaderValue[] items)Public Function ReplaceAll(items As HttpContentCodingHeaderValue[]) As voidpublic void ReplaceAll(HttpContentCodingHeaderValue[] items)

    Parameters

    • items
      Windows.Web.Http.Headers.HttpContentCodingHeaderValue[]
      Windows.Web.Http.Headers.HttpContentCodingHeaderValue[]
      Windows.Web.Http.Headers.HttpContentCodingHeaderValue[]
      Windows.Web.Http.Headers.HttpContentCodingHeaderValue[]

      The HttpContentCodingHeaderValue items to add to the collection.

  • SetAt(UInt32, HttpContentCodingHeaderValue)
    SetAt(UInt32, HttpContentCodingHeaderValue)
    SetAt(UInt32, HttpContentCodingHeaderValue)
    SetAt(UInt32, HttpContentCodingHeaderValue)

    Sets the HttpContentCodingHeaderValue at the specified index in the collection.

    public void SetAt(UInt32 index, HttpContentCodingHeaderValue value)public void SetAt(UInt32 index, HttpContentCodingHeaderValue value)Public Function SetAt(index As UInt32, value As HttpContentCodingHeaderValue) As voidpublic void SetAt(UInt32 index, HttpContentCodingHeaderValue value)

    Parameters

  • ToString()
    ToString()
    ToString()
    ToString()

    Returns a string that represents the current HttpContentCodingHeaderValueCollection object.

    public string ToString()public string ToString()Public Function ToString() As stringpublic string ToString()

    Returns

    • string
      string
      string
      string

      A string that represents the current object.

  • TryParseAdd(String)
    TryParseAdd(String)
    TryParseAdd(String)
    TryParseAdd(String)

    Tries to parse and add the specified item to the HttpContentCodingHeaderValueCollection.

    public bool TryParseAdd(String input)public bool TryParseAdd(String input)Public Function TryParseAdd(input As String) As boolpublic bool TryParseAdd(String input)

    Parameters

    • input
      System.String
      System.String
      System.String
      System.String

      The item to parse and add.

    Returns

    • bool
      bool
      bool
      bool

      true if the item successfully parsed and was added; otherwise false.

Device family

Windows 10 (introduced v10.0.10240.0)

API contract

Windows.Foundation.UniversalApiContract (introduced v1)

Attributes

Windows.Foundation.Metadata.ContractVersionAttribute
Windows.Foundation.Metadata.DualApiPartitionAttribute
Windows.Foundation.Metadata.MarshalingBehaviorAttribute
Windows.Foundation.Metadata.ThreadingAttribute

Details

Assembly

Windows.Web.Http.Headers.dll