Last change
on this file since 108 was
81,
checked in by rosiere, 16 years ago
|
- Finish Environment (and test)
- Continue predictor_unit
- Add external tools
- svn keyword "Id" set
|
-
Property svn:keywords set to
Id
|
File size:
948 bytes
|
Line | |
---|
1 | /* |
---|
2 | * |
---|
3 | * [desc.] |
---|
4 | */ |
---|
5 | #include "Tools/Viewer/Parser/include/parser.h" |
---|
6 | using namespace morpheo::tools::viewer::bdd; |
---|
7 | namespace morpheo{ |
---|
8 | namespace tools{ |
---|
9 | namespace viewer{ |
---|
10 | namespace parser{ |
---|
11 | |
---|
12 | void Parse::parser_param(QDomNode n,int level){ |
---|
13 | while( !n.isNull() ) |
---|
14 | { |
---|
15 | QDomElement e = n.toElement(); |
---|
16 | QDomNamedNodeMap a; |
---|
17 | QDomAttr ab; |
---|
18 | unsigned i; |
---|
19 | if( !e.isNull() ) |
---|
20 | { |
---|
21 | group=new Group(e.tagName().toStdString(),level); |
---|
22 | a=e.attributes(); |
---|
23 | for(i=0;i<a.length();i++) |
---|
24 | { |
---|
25 | ab=a.item(i).toAttr(); |
---|
26 | param=new Param(ab.name().toStdString(),ab.value().toInt(),e.tagName().toStdString()); |
---|
27 | //cout << ab.name().toStdString()<<endl; |
---|
28 | group->addParam(param); |
---|
29 | delete param; |
---|
30 | } |
---|
31 | base->addGroup(group); |
---|
32 | delete group; |
---|
33 | parser_param(n.firstChild(),level+1); |
---|
34 | } |
---|
35 | n = n.nextSibling(); //next channel |
---|
36 | |
---|
37 | } |
---|
38 | |
---|
39 | } |
---|
40 | |
---|
41 | };//end parser |
---|
42 | };//end viewer |
---|
43 | };//end tools |
---|
44 | };//end morpheo |
---|
45 | |
---|
Note: See
TracBrowser
for help on using the repository browser.