Last change
on this file since 125 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:
1.1 KB
|
Rev | Line | |
---|
[31] | 1 | #ifdef POSITION |
---|
| 2 | /* |
---|
| 3 | * $Id: Component_toXML.cpp 81 2008-04-15 18:40:01Z rosiere $ |
---|
| 4 | * |
---|
| 5 | * [ Description ] |
---|
| 6 | * |
---|
| 7 | */ |
---|
| 8 | |
---|
[42] | 9 | #include "Behavioural/include/Component.h" |
---|
[81] | 10 | #include "Behavioural/include/Version.h" |
---|
[31] | 11 | |
---|
| 12 | namespace morpheo { |
---|
| 13 | namespace behavioural { |
---|
| 14 | |
---|
[43] | 15 | #undef FUNCTION |
---|
| 16 | #define FUNCTION "Component::toXML" |
---|
| 17 | |
---|
[42] | 18 | XML Component::toXML (void) |
---|
[31] | 19 | { |
---|
[43] | 20 | log_printf(FUNC,Behavioural,FUNCTION,"Begin"); |
---|
| 21 | |
---|
[42] | 22 | XML xml (_entity->get_name()); |
---|
[31] | 23 | |
---|
[81] | 24 | xml.balise_open_begin ("description"); |
---|
| 25 | xml. attribut("morpheo_version",MORPHEO_VERSION); |
---|
| 26 | xml.balise_open_end(); |
---|
[31] | 27 | xml. insert_XML (_entity->toXML()); |
---|
| 28 | xml. balise_open ("architecture"); |
---|
| 29 | |
---|
| 30 | if (_list_component->empty()== false) |
---|
| 31 | { |
---|
[75] | 32 | std::list<Tcomponent_t *>::iterator i = _list_component->begin(); |
---|
[31] | 33 | |
---|
| 34 | while (i != _list_component->end()) |
---|
| 35 | { |
---|
[57] | 36 | xml.insert_XML ((*i)->_entity->toXML_mapping()); |
---|
[31] | 37 | ++i; |
---|
| 38 | } |
---|
| 39 | } |
---|
| 40 | |
---|
| 41 | xml. balise_close (); |
---|
| 42 | xml.balise_close (); |
---|
[43] | 43 | |
---|
| 44 | log_printf(FUNC,Behavioural,FUNCTION,"End"); |
---|
| 45 | |
---|
[31] | 46 | return xml; |
---|
| 47 | }; |
---|
| 48 | |
---|
| 49 | }; // end namespace behavioural |
---|
| 50 | }; // end namespace morpheo |
---|
| 51 | #endif |
---|
Note: See
TracBrowser
for help on using the repository browser.