comparison m-toolbox/m/gui/ltpdv/callbacks/ltpdv_getWorkspaceObjs.m @ 0:f0afece42f48

Import.
author Daniele Nicolodi <nicolodi@science.unitn.it>
date Wed, 23 Nov 2011 19:22:13 +0100
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:f0afece42f48
1 function objs = ltpdv_getWorkspaceObjs()
2 % LTPDV_GETWORKSPACEOBJS gets a list of LTPDA user objects currently in the
3 % MATLAB workspace.
4 %
5 % M Hewitson 22-04-08
6 %
7 % $Id: ltpdv_getWorkspaceObjs.m,v 1.2 2008/06/18 15:07:35 hewitson Exp $
8 %
9
10 % get base workspace variables
11 ws_vars = evalin('base','whos');
12
13 objs = [];
14 for j=1:length(ws_vars)
15
16 cmd = sprintf('obj = evalin(''base'', ''%s'');', ws_vars(j).name);
17 eval(cmd)
18 if isa(obj, 'ltpda_uo')
19 objs = [objs ws_vars(j)];
20 end
21
22 end
23