comparison m-toolbox/classes/@timespan/timespan.m @ 23:a71a40911c27 database-connection-manager

Update check for repository connection parameter in constructors
author Daniele Nicolodi <nicolodi@science.unitn.it>
date Mon, 05 Dec 2011 16:20:06 +0100
parents f0afece42f48
children
comparison
equal deleted inserted replaced
22:b11e88004fca 23:a71a40911c27
213 %%%%%%%%%% ts = timespan(time, '14:00:05') %%%%%%%%%% 213 %%%%%%%%%% ts = timespan(time, '14:00:05') %%%%%%%%%%
214 utils.helper.msg(msg.OPROC1, 'constructing from start/end time'); 214 utils.helper.msg(msg.OPROC1, 'constructing from start/end time');
215 pli = plist('startT', varargin{1}, 'endT', varargin{2}); 215 pli = plist('startT', varargin{1}, 'endT', varargin{2});
216 obj = obj.fromTimespanDef(pli); 216 obj = obj.fromTimespanDef(pli);
217 217
218 elseif (isa(varargin{1}, 'database') || isa(varargin{1}, 'mpipeline.repository.RepositoryConnection')) && isnumeric(varargin{2}) 218 elseif (isa(varargin{1}, 'database') || isa(varargin{1}, 'java.sql.Connection')) && isnumeric(varargin{2})
219 %%%%%%%%%% f = timespan(database, IDs) %%%%%%%%%% 219 %%%%%%%%%% f = timespan(database, IDs) %%%%%%%%%%
220 utils.helper.msg(msg.OPROC1, 'retrieve from repository'); 220 utils.helper.msg(msg.OPROC1, 'retrieve from repository');
221 obj = obj.fromRepository(plist('conn', varargin{1}, 'id', varargin{2})); 221 obj = obj.fromRepository(plist('conn', varargin{1}, 'id', varargin{2}));
222 222
223 elseif isa(varargin{1}, 'timespan') && isa(varargin{2}, 'plist') && isempty(varargin{2}.params) 223 elseif isa(varargin{1}, 'timespan') && isa(varargin{2}, 'plist') && isempty(varargin{2}.params)