source: trunk/IPs/systemC/processor/Morpheo/Behavioural/src/Vhdl_get_entity.cpp @ 2

Last change on this file since 2 was 2, checked in by kane, 17 years ago

Import Morpheo

File size: 822 bytes
Line 
1#ifdef VHDL
2
3/*
4 * $Id$
5 *
6 * [ Description ]
7 *
8 */
9
10#include "Behavioural/include/Vhdl.h"
11
12#include <sstream>
13using namespace std;
14
15namespace morpheo              {
16namespace behavioural          {
17 
18  string Vhdl::get_entity(uint32_t depth,
19                          string   name)
20  {
21    string        tab = string(depth,'\t');
22    ostringstream text;
23
24    text <<                                      endl
25         << tab << "entity " << name << " is" << endl;
26
27    if (_list_port.empty() == false)
28      text << tab << "\tport ("                 << endl
29           << tab << get_port(depth+1)          << endl
30           << tab << "\t     );"                << endl;
31   
32    text << tab << "end " << name << ";"      << endl;
33   
34    return text.str();
35  };
36 
37}; // end namespace behavioural         
38}; // end namespace morpheo             
39
40#endif
Note: See TracBrowser for help on using the repository browser.