def set_value(self, value, **kwargs):
        """

        kwargs are passed on to filter
        """
        _orig_value = deepcopy(self.get_value())

        if self._bundle is None:
            raise ValueError("ConstraintParameters must be attached from the bundle, and cannot be standalone")
        value = str(value) # <-- in case unicode
        # if the user wants to see the expression, we'll replace all
        # var.safe_label with var.curly_label
        self._value, self._vars = self._parse_expr(value)
        # reset the cached version of the PS - will be recomputed on next request
        self._var_params = None
        #~ print "***", self.uniquetwig, self.uniqueid
        self._add_history(redo_func='set_value', redo_kwargs={'value': value, 'uniqueid': self.uniqueid}, undo_func='set_value', undo_kwargs={'value': _orig_value, 'uniqueid': self.uniqueid})
def set_value ( self , value , ** kwargs ) : _orig_value = deepcopy ( self . get_value ( ) ) if self . _bundle is None : raise ValueError ( "ConstraintParameters must be attached from the bundle, and cannot be standalone" ) value = str ( value ) self . _value , self . _vars = self . _parse_expr ( value ) self . _var_params = None self . _add_history ( redo_func = 'set_value' , redo_kwargs = { 'value' : value , 'uniqueid' : self . uniqueid } , undo_func = 'set_value' , undo_kwargs = { 'value' : _orig_value , 'uniqueid' : self . uniqueid } )
kwargs are passed on to filter