Last change
on this file since 91 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.0 KB
|
Rev | Line | |
---|
[2] | 1 | #ifdef VHDL |
---|
| 2 | |
---|
| 3 | /* |
---|
| 4 | * $Id: Vhdl_get_entity.cpp 81 2008-04-15 18:40:01Z rosiere $ |
---|
| 5 | * |
---|
| 6 | * [ Description ] |
---|
| 7 | * |
---|
| 8 | */ |
---|
| 9 | |
---|
| 10 | #include "Behavioural/include/Vhdl.h" |
---|
| 11 | |
---|
| 12 | #include <sstream> |
---|
| 13 | |
---|
| 14 | namespace morpheo { |
---|
| 15 | namespace behavioural { |
---|
| 16 | |
---|
[43] | 17 | #undef FUNCTION |
---|
| 18 | #define FUNCTION "Vhdl::get_entity" |
---|
[71] | 19 | std::string Vhdl::get_entity(uint32_t depth, |
---|
| 20 | std::string name) |
---|
[2] | 21 | { |
---|
[43] | 22 | log_printf(FUNC,Behavioural,FUNCTION,"Begin"); |
---|
| 23 | |
---|
[71] | 24 | std::string tab = std::string(depth,'\t'); |
---|
| 25 | std::ostringstream text; |
---|
[2] | 26 | |
---|
[71] | 27 | text << std::endl |
---|
| 28 | << tab << "entity " << name << " is" << std::endl; |
---|
| 29 | |
---|
[2] | 30 | if (_list_port.empty() == false) |
---|
[71] | 31 | text << tab << "\tport (" << std::endl |
---|
| 32 | << tab << get_port(depth+1) << std::endl |
---|
| 33 | << tab << "\t );" << std::endl; |
---|
[2] | 34 | |
---|
[71] | 35 | text << tab << "end " << name << ";" << std::endl; |
---|
[2] | 36 | |
---|
[43] | 37 | log_printf(FUNC,Behavioural,FUNCTION,"End"); |
---|
| 38 | |
---|
[2] | 39 | return text.str(); |
---|
| 40 | }; |
---|
| 41 | |
---|
| 42 | }; // end namespace behavioural |
---|
| 43 | }; // end namespace morpheo |
---|
| 44 | |
---|
| 45 | #endif |
---|
Note: See
TracBrowser
for help on using the repository browser.