Author: bugman Date: Thu Jan 19 11:33:48 2012 New Revision: 15190 URL: http://svn.gna.org/viewcvs/relax?rev=15190&view=rev Log: The Param_list.get_units() method can now handle function type objects. This is needed for the model-free Rex parameter. Modified: branches/spec_api/specific_fns/api_objects.py Modified: branches/spec_api/specific_fns/api_objects.py URL: http://svn.gna.org/viewcvs/relax/branches/spec_api/specific_fns/api_objects.py?rev=15190&r1=15189&r2=15190&view=diff ============================================================================== --- branches/spec_api/specific_fns/api_objects.py (original) +++ branches/spec_api/specific_fns/api_objects.py Thu Jan 19 11:33:48 2012 @@ -173,5 +173,9 @@ if name not in self._names: raise RelaxError("The parameter '%s' does not exist." % name) + # Function. + if isinstance(self._units[name], FunctionType): + return self._units[name]() + # Return the value. return self._units[name]