[2] | 1 | #ifdef VHDL |
---|
| 2 | |
---|
| 3 | /* |
---|
| 4 | * $Id: Vhdl_set_body.cpp 94 2008-12-15 11:04:03Z rosiere $ |
---|
| 5 | * |
---|
| 6 | * [ Description ] |
---|
| 7 | * |
---|
| 8 | */ |
---|
| 9 | |
---|
| 10 | #include "Behavioural/include/Vhdl.h" |
---|
[94] | 11 | #include "Common/include/Tabulation.h" |
---|
[2] | 12 | #include <sstream> |
---|
| 13 | |
---|
| 14 | namespace morpheo { |
---|
| 15 | namespace behavioural { |
---|
| 16 | |
---|
[43] | 17 | #undef FUNCTION |
---|
| 18 | #define FUNCTION "Vhdl::set_body" |
---|
[88] | 19 | void Vhdl::set_body (std::string text) |
---|
[2] | 20 | { |
---|
[43] | 21 | log_printf(FUNC,Behavioural,FUNCTION,"Begin"); |
---|
[94] | 22 | set_body(0, text); |
---|
[43] | 23 | log_printf(FUNC,Behavioural,FUNCTION,"End"); |
---|
[2] | 24 | }; |
---|
[94] | 25 | |
---|
| 26 | #undef FUNCTION |
---|
| 27 | #define FUNCTION "Vhdl::set_body" |
---|
| 28 | void Vhdl::set_body (uint32_t depth, |
---|
| 29 | std::string text) |
---|
| 30 | { |
---|
| 31 | log_printf(FUNC,Behavioural,FUNCTION,"Begin"); |
---|
| 32 | set_list(_list_body, morpheo::tab(depth)+text); |
---|
| 33 | log_printf(FUNC,Behavioural,FUNCTION,"End"); |
---|
| 34 | }; |
---|
[2] | 35 | |
---|
[88] | 36 | #undef FUNCTION |
---|
| 37 | #define FUNCTION "Vhdl::set_body" |
---|
[94] | 38 | void Vhdl::set_body (uint32_t depth, |
---|
| 39 | Vhdl * vhdl) |
---|
[88] | 40 | { |
---|
| 41 | log_printf(FUNC,Behavioural,FUNCTION,"Begin"); |
---|
| 42 | |
---|
[94] | 43 | std::string tab=morpheo::tab(depth); |
---|
| 44 | |
---|
[88] | 45 | for (std::list<std::string>::iterator it=vhdl->_list_body.begin(); |
---|
| 46 | it!=vhdl->_list_body.end(); |
---|
| 47 | ++it) |
---|
[94] | 48 | set_list(_list_body,tab+*it); |
---|
[88] | 49 | |
---|
| 50 | log_printf(FUNC,Behavioural,FUNCTION,"End"); |
---|
| 51 | }; |
---|
| 52 | |
---|
[2] | 53 | }; // end namespace behavioural |
---|
| 54 | }; // end namespace morpheo |
---|
| 55 | |
---|
| 56 | #endif |
---|