- Timestamp:
- 05/29/05 00:05:02 (20 years ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
tea4cups/trunk/tea4cups
r636 r638 107 107 print " %s : %s" % (key, attrdict[key]) 108 108 """ 109 attributes_types = ("operation", "job", "printer", "unsupported") 109 110 def __init__(self, data, debug=0) : 110 111 """Initializes and parses IPP Message object. … … 117 118 self.debug = debug 118 119 self.data = data 119 self.operation_attributes = {} 120 self.job_attributes = {} 121 self.printer_attributes = {} 122 self.unsupported_attributes = {} 120 for attrtype in self.attributes_types : 121 setattr(self, "%s_attributes" % attrtype, {}) 123 122 self.tags = [ None ] * 256 # by default all tags reserved 124 123 … … 247 246 248 247 # Now transform all one-element lists into single values 249 for attrtype in ("operation", "job", "printer"):248 for attrtype in self.attributes_types : 250 249 attrdict = getattr(self, "%s_attributes" % attrtype) 251 250 for (key, value) in attrdict.items() :