Show
Ignore:
Timestamp:
06/11/08 16:56:28 (3 months ago)
Author:
edsuom
Message:

Bug fix to new FlexArray? jellying feature

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • projects/Twisted-Goodies/trunk/twisted_goodies/pybywire/params.py

    r210 r212  
    115115    def __setattr__(self, name, value): 
    116116        """ 
    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': 
    121123            if not hasattr(self, name): 
    122124                isDifferent = True 
     
    186188                        if '_flexArrays' not in state: 
    187189                            state['_flexArrays'] = [] 
    188                         state['_flexArrays'].append(name, value.asTuple()) 
     190                        state['_flexArrays'].append((name, value.asTuple())) 
    189191                    else: 
    190192                        state[name] = value