set_cookie


Description:

[ Version ( since = "2.24" ) ]
public void set_cookie (URI uri, string cookie)

Adds cookie to this, exactly as though it had appeared in a Set-Cookie header returned from a request to uri.

Keep in mind that if the CookieJarAcceptPolicy set is either NO_THIRD_PARTY or GRANDFATHERED_THIRD_PARTY you'll need to use set_cookie_with_first_party, otherwise the jar will have no way of knowing if the cookie is being set by a third party or not.

Parameters:

this

a CookieJar

uri

the URI setting the cookie

cookie

the stringified cookie to set