#include <sc_export.h>
Public メソッド | |
void | insert (sc_export_base *) |
void | remove (sc_export_base *) |
int | size () const |
Private メソッド | |
sc_export_registry (sc_simcontext &simc_) | |
~sc_export_registry () | |
void | construction_done () |
void | elaboration_done () |
void | start_simulation () |
void | simulation_done () |
sc_export_registry () | |
sc_export_registry (const sc_export_registry &) | |
sc_export_registry & | operator= (const sc_export_registry &) |
Private 変数 | |
sc_simcontext * | m_simc |
std::vector< sc_export_base * > | m_export_vec |
フレンド | |
class | sc_simcontext |
sc_export.h の 222 行で定義されています。
sc_core::sc_export_registry::sc_export_registry | ( | sc_simcontext & | simc_ | ) | [explicit, private] |
sc_core::sc_export_registry::~sc_export_registry | ( | ) | [private] |
sc_core::sc_export_registry::sc_export_registry | ( | ) | [private] |
sc_core::sc_export_registry::sc_export_registry | ( | const sc_export_registry & | ) | [private] |
void sc_core::sc_export_registry::insert | ( | sc_export_base * | export_ | ) |
sc_export.cpp の 109 行で定義されています。
00110 { 00111 if( sc_is_running() ) { 00112 SC_REPORT_ERROR(SC_ID_SC_EXPORT_AFTER_START_, export_->name()); 00113 } 00114 00115 #ifdef DEBUG_SYSTEMC 00116 // check if port_ is already inserted 00117 for( int i = size() - 1; i >= 0; -- i ) { 00118 if( export_ == m_export_vec[i] ) { 00119 SC_REPORT_ERROR(SC_ID_SC_EXPORT_ALREADY_REGISTERED_, export_->name()); 00120 } 00121 } 00122 #endif 00123 00124 /* 00125 //TBD: maybe we want to do this stuf for later 00126 00127 // append the port to the current module's vector of ports 00128 sc_module* curr_module = m_simc->hierarchy_curr(); 00129 if( curr_module == 0 ) { 00130 port_->report_error( SC_ID_PORT_OUTSIDE_MODULE_ ); 00131 } 00132 curr_module->append_port( port_ ); 00133 */ 00134 00135 // insert 00136 m_export_vec.push_back( export_ ); 00137 }
void sc_core::sc_export_registry::remove | ( | sc_export_base * | export_ | ) |
sc_export.cpp の 140 行で定義されています。
00141 { 00142 if (size()==0) return; 00143 int i; 00144 for( i = size() - 1; i >= 0; -- i ) { 00145 if( export_ == m_export_vec[i] ) { 00146 break; 00147 } 00148 } 00149 if( i == -1 ) { 00150 SC_REPORT_ERROR(SC_ID_SC_EXPORT_NOT_REGISTERED_, export_->name()); 00151 } 00152 00153 // remove 00154 m_export_vec[i] = m_export_vec[size() - 1]; 00155 m_export_vec.resize(size()-1); 00156 }
int sc_core::sc_export_registry::size | ( | ) | const [inline] |
void sc_core::sc_export_registry::construction_done | ( | ) | [private] |
sc_export.cpp の 175 行で定義されています。
00176 { 00177 for( int i = size() - 1; i >= 0; -- i ) { 00178 sc_export_base* e = m_export_vec[i]; 00179 if (e->get_interface() == 0) { 00180 SC_REPORT_ERROR(SC_ID_SC_EXPORT_NOT_BOUND_AFTER_CONSTRUCTION_, 00181 e->name()); 00182 } 00183 e->before_end_of_elaboration(); 00184 } 00185 }
void sc_core::sc_export_registry::elaboration_done | ( | ) | [private] |
sc_export.cpp の 190 行で定義されています。
00191 { 00192 for( int i = size() - 1; i >= 0; -- i ) { 00193 m_export_vec[i]->end_of_elaboration(); 00194 } 00195 }
void sc_core::sc_export_registry::start_simulation | ( | ) | [private] |
sc_export.cpp の 200 行で定義されています。
00201 { 00202 for( int i = size() - 1; i >= 0; -- i ) { 00203 m_export_vec[i]->start_of_simulation(); 00204 } 00205 }
void sc_core::sc_export_registry::simulation_done | ( | ) | [private] |
sc_export.cpp の 208 行で定義されています。
00209 { 00210 for( int i = size() - 1; i >= 0; -- i ) { 00211 m_export_vec[i]->end_of_simulation(); 00212 } 00213 }
sc_export_registry& sc_core::sc_export_registry::operator= | ( | const sc_export_registry & | ) | [private] |
friend class sc_simcontext [friend] |
sc_export.h の 224 行で定義されています。
sc_simcontext* sc_core::sc_export_registry::m_simc [private] |
sc_export.h の 256 行で定義されています。
std::vector<sc_export_base*> sc_core::sc_export_registry::m_export_vec [private] |
sc_export.h の 257 行で定義されています。