Back to index

python3.2  3.2.2
Public Member Functions
http.cookiejar.CookiePolicy Class Reference
Inheritance diagram for http.cookiejar.CookiePolicy:
Inheritance graph
[legend]

List of all members.

Public Member Functions

def set_ok
def return_ok
def domain_return_ok
def path_return_ok

Detailed Description

Defines which cookies get accepted from and returned to server.

May also modify cookies, though this is probably a bad idea.

The subclass DefaultCookiePolicy defines the standard rules for Netscape
and RFC 2965 cookies -- override that if you want a customised policy.

Definition at line 811 of file cookiejar.py.


Member Function Documentation

def http.cookiejar.CookiePolicy.domain_return_ok (   self,
  domain,
  request 
)
Return false if cookies should not be returned, given cookie domain.

Reimplemented in http.cookiejar.DefaultCookiePolicy.

Definition at line 833 of file cookiejar.py.

00833 
00834     def domain_return_ok(self, domain, request):
00835         """Return false if cookies should not be returned, given cookie domain.
00836         """
00837         return True

def http.cookiejar.CookiePolicy.path_return_ok (   self,
  path,
  request 
)
Return false if cookies should not be returned, given cookie path.

Reimplemented in http.cookiejar.DefaultCookiePolicy.

Definition at line 838 of file cookiejar.py.

00838 
00839     def path_return_ok(self, path, request):
00840         """Return false if cookies should not be returned, given cookie path.
00841         """
00842         return True
00843 

def http.cookiejar.CookiePolicy.return_ok (   self,
  cookie,
  request 
)
Return true if (and only if) cookie should be returned to server.

Reimplemented in http.cookiejar.DefaultCookiePolicy.

Definition at line 829 of file cookiejar.py.

00829 
00830     def return_ok(self, cookie, request):
00831         """Return true if (and only if) cookie should be returned to server."""
00832         raise NotImplementedError()

def http.cookiejar.CookiePolicy.set_ok (   self,
  cookie,
  request 
)
Return true if (and only if) cookie should be accepted from server.

Currently, pre-expired cookies never get this far -- the CookieJar
class deletes such cookies itself.

Reimplemented in http.cookiejar.DefaultCookiePolicy.

Definition at line 820 of file cookiejar.py.

00820 
00821     def set_ok(self, cookie, request):
00822         """Return true if (and only if) cookie should be accepted from server.
00823 
00824         Currently, pre-expired cookies never get this far -- the CookieJar
00825         class deletes such cookies itself.
00826 
00827         """
00828         raise NotImplementedError()


The documentation for this class was generated from the following file: