CookieHeaderValue Class

 

Provides value for the cookie header.

Namespace:   System.Net.Http.Headers
Assembly:  System.Net.Http.Formatting (in System.Net.Http.Formatting.dll)

Inheritance Hierarchy

System.Object
  System.Net.Http.Headers.CookieHeaderValue

Syntax

[DefaultMemberAttribute("Item")]
public class CookieHeaderValue : ICloneable
[DefaultMemberAttribute("Item")]
public ref class CookieHeaderValue : ICloneable
[<DefaultMemberAttribute("Item")>]
type CookieHeaderValue = 
    class
        interface ICloneable
    end
<DefaultMemberAttribute("Item")>
Public Class CookieHeaderValue
    Implements ICloneable

Constructors

Name Description
System_CAPS_protmethod CookieHeaderValue()

Initializes a new instance of the CookieHeaderValue class.

System_CAPS_pubmethod CookieHeaderValue(String, NameValueCollection)

Initializes a new instance of the CookieHeaderValue class.

System_CAPS_pubmethod CookieHeaderValue(String, String)

Initializes a new instance of the CookieHeaderValue class.

Properties

Name Description
System_CAPS_pubproperty Cookies

Gets a collection of cookies sent by the client.

System_CAPS_pubproperty Domain

Gets or sets the domain to associate the cookie with.

System_CAPS_pubproperty Expires

Gets or sets the expiration date and time for the cookie.

System_CAPS_pubproperty HttpOnly

Gets or sets a value that specifies whether a cookie is accessible by client-side script.

System_CAPS_pubproperty Item[String]

Gets a shortcut to the cookie property.

System_CAPS_pubproperty MaxAge

Gets or sets the maximum age permitted for a resource.

System_CAPS_pubproperty Path

Gets or sets the virtual path to transmit with the current cookie.

System_CAPS_pubproperty Secure

Gets or sets a value indicating whether to transmit the cookie using Secure Sockets Layer (SSL)—that is, over HTTPS only.

Methods

Name Description
System_CAPS_pubmethod Clone()

Creates a shallow copy of the cookie value.

System_CAPS_pubmethod Equals(Object)

(Inherited from Object.)

System_CAPS_protmethod Finalize()

(Inherited from Object.)

System_CAPS_pubmethod GetHashCode()

(Inherited from Object.)

System_CAPS_pubmethod GetType()

(Inherited from Object.)

System_CAPS_protmethod MemberwiseClone()

(Inherited from Object.)

System_CAPS_pubmethod ToString()

Returns a string that represents the current object.(Overrides Object.ToString().)

System_CAPS_pubmethodSystem_CAPS_static TryParse(String, CookieHeaderValue)

Indicates a value whether the string representation will be converted.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

System.Net.Http.Headers Namespace

Return to top