diff m-toolbox/classes/@collection/collection.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
line wrap: on
line diff
--- a/m-toolbox/classes/@collection/collection.m	Mon Dec 05 16:20:06 2011 +0100
+++ b/m-toolbox/classes/@collection/collection.m	Mon Dec 05 16:20:06 2011 +0100
@@ -155,7 +155,7 @@
             inObjs = [num2cell(reshape(varargin{1}, 1, [])), num2cell(reshape(varargin{2}, 1, []))];
             obj = obj.fromInput(plist('objs', inObjs));
             
-          elseif (isa(varargin{1}, 'database') || isa(varargin{1}, 'mpipeline.repository.RepositoryConnection')) && isnumeric(varargin{2})
+          elseif (isa(varargin{1}, 'database') || isa(varargin{1}, 'java.sql.Connection')) && isnumeric(varargin{2})
             %%%%%%%%%%  f = collection(<database-object>, [IDs])   %%%%%%%%%%
             utils.helper.msg(msg.OPROC1, 'retrieve from repository');
             obj = obj.fromRepository(plist('conn', varargin{1}, 'id', varargin{2}));