System.Web (system.web.dll) | sealed class |
HttpCookieCollection is a name/value collection
of HttpCookie objects. The
Cookies property of the
HttpResponse class contains the cookies sent from
the client with the current request. The Cookies
property of the HttpRequest class contains the
cookies sent back from the server.
These collections contain all the transmitted cookies, including
those you have created automatically in code, and other cookies used
by the ASP.NET framework like the Forms Authentication cookie and the
Session state cookie (named ASP.NET_SessionId).
public sealed class HttpCookieCollection : System.Collections.Specialized.NameObjectCollectionBase {
// Public Constructors
public HttpCookieCollection( );
// Public Instance Properties
public string[ ] AllKeys{get; }
public HttpCookie this[int index]{get; }
public HttpCookie this[string name]{get; }
// Public Instance Methods
public void Add(HttpCookie cookie);
public void Clear( );
public void CopyTo(Array dest, int index); // implements ICollection
public HttpCookie Get(int index);
public HttpCookie Get(string name);
public string GetKey(int index);
public void Remove(string name);
public void Set(HttpCookie cookie);
}
Hierarchy
System.Object
System.Collections.Specialized.NameObjectCollectionBase(System.Collections.ICollection,
System.Collections.IEnumerable,
System.Runtime.Serialization.ISerializable,
System.Runtime.Serialization.IDeserializationCallback)
HttpCookieCollection
Returned By
HttpRequest.Cookies,
HttpResponse.Cookies
|