comparison m-toolbox/classes/@mfir/attachToDom.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
2 function collectedHist = attachToDom(objs, dom, parent, collectedHist)
3
4 if isempty(objs)
5
6 % create empty mfir node with the attribute 'shape'
7 utils.xml.attachEmptyObjectNode(objs, dom, parent);
8
9 else
10 for oo = 1:numel(objs)
11 obj = objs(oo);
12
13 % create object node
14 mfirNode = dom.createElement('mfir');
15 mfirNode.setAttribute('shape', sprintf('%dx%d', size(objs)));
16
17 % call superclass
18 collectedHist = attachToDom@ltpda_filter(obj, dom, mfirNode, collectedHist);
19
20 % add histout
21 gdNode = dom.createElement('gd');
22 utils.xml.attachNumberToDom(obj.gd, dom, gdNode);
23 mfirNode.appendChild(gdNode);
24
25 % add to parent node
26 parent.appendChild(mfirNode);
27
28 end
29 end
30
31 end