Changeset 212
- Timestamp:
- 06/11/08 16:56:28 (7 months ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
projects/Twisted-Goodies/trunk/twisted_goodies/pybywire/params.py
r210 r212 115 115 def __setattr__(self, name, value): 116 116 """ 117 Sets the attribute I{name} to the supplied I{value}, clearing the cache 118 if the attribute is a parameter and its value will be (re)defined. 119 """ 120 if name in self.paramNames or name in self.keyAttrs: 117 Sets the attribute I{name} to the supplied I{value}. Clears the cache 118 if the attribute is a parameter, key attribute, or the list of 119 parameter names itself, and if its value will be (re)defined. 120 """ 121 if name in self.paramNames or \ 122 name in self.keyAttrs or name == 'paramNames': 121 123 if not hasattr(self, name): 122 124 isDifferent = True … … 186 188 if '_flexArrays' not in state: 187 189 state['_flexArrays'] = [] 188 state['_flexArrays'].append( name, value.asTuple())190 state['_flexArrays'].append((name, value.asTuple())) 189 191 else: 190 192 state[name] = value
