Back to index

system-config-printer  1.3.9+20120706
Public Member Functions | Public Attributes
authconn._AuthInfoCache Class Reference

List of all members.

Public Member Functions

def __init__
def cache_auth_info
def lookup_auth_info
def remove_auth_info

Public Attributes

 creds

Detailed Description

Definition at line 117 of file authconn.py.


Constructor & Destructor Documentation

Definition at line 118 of file authconn.py.

00118 
00119     def __init__ (self):
00120         self.creds = dict() # by (host,port)


Member Function Documentation

def authconn._AuthInfoCache.cache_auth_info (   self,
  data,
  host = None,
  port = None 
)

Definition at line 121 of file authconn.py.

00121 
00122     def cache_auth_info (self, data, host=None, port=None):
00123         if port == None:
00124             port = 631
00125 
00126         self.creds[(host,port)] = data

def authconn._AuthInfoCache.lookup_auth_info (   self,
  host = None,
  port = None 
)

Definition at line 127 of file authconn.py.

00127 
00128     def lookup_auth_info (self, host=None, port=None):
00129         if port == None:
00130             port = 631
00131 
00132         try:
00133             return self.creds[(host,port)]
00134         except KeyError:
00135             return None

def authconn._AuthInfoCache.remove_auth_info (   self,
  host = None,
  port = None 
)

Definition at line 136 of file authconn.py.

00136 
00137     def remove_auth_info (self, host=None, port=None):
00138         if port == None:
00139             port = 631
00140 
00141         try:
00142             del self.creds[(host,port)]
00143         except KeyError:
00144             return None


Member Data Documentation

Definition at line 119 of file authconn.py.


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