Mercurial > hg > ltpda
view m-toolbox/classes/@ssm/doSetParameters.m @ 52:daf4eab1a51e database-connection-manager tip
Fix. Default password should be [] not an empty string
author | Daniele Nicolodi <nicolodi@science.unitn.it> |
---|---|
date | Wed, 07 Dec 2011 17:29:47 +0100 |
parents | f0afece42f48 |
children |
line wrap: on
line source
% DOSETPARAMETERS Sets the values of the given parameters. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % DESCRIPTION: DOSETPARAMETERS Sets the values of the given parameters. % % CALL: obj = obj.setParameters({'key1', ...}, [val1, ...]); % obj = obj.setParameters(plist); % obj = obj.setParameters('key', val); % % VERSION: $Id: doSetParameters.m,v 1.2 2011/02/22 15:41:16 hewitson Exp $ % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% function sys = doSetParameters(sys, setnames, setvalues) Nset = numel(setvalues); for j=1:Nset if ~any(strcmpi(setnames{j}, {sys.params.params.key})) warning(['### parameter named ' setnames{j} ' was not found in system ' sys.name]) else sys.params.pset( setnames{j}, setvalues(j) ); end end end