OpenASIP
2.0
|
#include <HWBlockImplementation.hh>
Public Member Functions | |
HWBlockImplementation (const std::string &moduleName, const std::string &clkPort, const std::string &rstPort, const std::string &glockPort) | |
HWBlockImplementation (const HWBlockImplementation &b) | |
virtual | ~HWBlockImplementation () |
bool | hasID () const |
void | setID (RowID id) |
RowID | id () const |
void | setModuleName (const std::string &name) |
std::string | moduleName () const |
void | setClkPort (const std::string &name) |
std::string | clkPort () const |
void | setRstPort (const std::string &name) |
std::string | rstPort () const |
void | setGlockPort (const std::string &name) |
std::string | glockPort () const |
void | addImplementationFile (BlockImplementationFile *file) |
void | removeImplementationFile (const BlockImplementationFile &file) |
int | implementationFileCount () const |
BlockImplementationFile & | file (int index) const |
Private Types | |
typedef std::vector< BlockImplementationFile * > | FileTable |
Vector type for BlockImplementationFile. More... | |
Private Attributes | |
std::string | moduleName_ |
Name of the module. More... | |
std::string | clkPort_ |
Name of the clock port. More... | |
std::string | rstPort_ |
Name of the reset port. More... | |
std::string | glockPort_ |
Name of the global lock port. More... | |
FileTable | files_ |
Contains the block implementation files. More... | |
bool | hasID_ |
Tells whether the implementation has an ID. More... | |
RowID | id_ |
ID of the implementation. More... | |
Base class for FUImplementation and RFImplementation.
Definition at line 49 of file HWBlockImplementation.hh.
|
private |
Vector type for BlockImplementationFile.
Definition at line 82 of file HWBlockImplementation.hh.
HDB::HWBlockImplementation::HWBlockImplementation | ( | const std::string & | moduleName, |
const std::string & | clkPort, | ||
const std::string & | rstPort, | ||
const std::string & | glockPort | ||
) |
The constructor.
moduleName | Name of the module. |
clkPort | Name of the clock port. |
rstPort | Name of the reset port. |
glockPort | Name of the global lock port. |
Definition at line 52 of file HWBlockImplementation.cc.
HDB::HWBlockImplementation::HWBlockImplementation | ( | const HWBlockImplementation & | original | ) |
Copy constructor.
original | HWBlock to copy. |
Definition at line 66 of file HWBlockImplementation.cc.
References addImplementationFile(), clkPort(), clkPort_, file(), glockPort(), glockPort_, hasID(), hasID_, id(), id_, implementationFileCount(), moduleName(), moduleName_, rstPort(), and rstPort_.
|
virtual |
The destructor.
Definition at line 94 of file HWBlockImplementation.cc.
References SequenceTools::deleteAllItems(), and files_.
void HDB::HWBlockImplementation::addImplementationFile | ( | BlockImplementationFile * | file | ) |
Adds a new implementation file for the block implementation.
file | The file to add. |
Definition at line 230 of file HWBlockImplementation.cc.
References file(), and files_.
Referenced by HWBlockImplementation().
std::string HDB::HWBlockImplementation::clkPort | ( | ) | const |
Returns the name of the clock signal port.
Definition at line 175 of file HWBlockImplementation.cc.
References clkPort_.
Referenced by HDB::HDBManager::addFUImplementation(), ProGe::NetlistGenerator::addFUToNetlist(), RFTestbenchGenerator::createTbInstantiation(), FUTestbenchGenerator::createTbInstantiation(), HDBToHtml::fuImplToHtml(), HWBlockImplementation(), HDBToHtml::rfImplToHtml(), and TestbenchGenerator::writeTestbench().
BlockImplementationFile & HDB::HWBlockImplementation::file | ( | int | index | ) | const |
Returns a block implementation file by the given index.
index | The index. |
OutOfRange | If the index is negative or not smaller than the number of files. |
Definition at line 267 of file HWBlockImplementation.cc.
References files_, and implementationFileCount().
Referenced by HDB::HDBManager::addFUImplementation(), addImplementationFile(), ImplementationTester::createListOfSimulationFiles(), HDBToHtml::fuImplToHtml(), ProGeScriptGenerator::getBlockOrder(), HWBlockImplementation(), removeImplementationFile(), and HDBToHtml::rfImplToHtml().
std::string HDB::HWBlockImplementation::glockPort | ( | ) | const |
Returns the name of the global lock port.
Definition at line 219 of file HWBlockImplementation.cc.
References glockPort_.
Referenced by HDB::HDBManager::addFUImplementation(), ProGe::NetlistGenerator::addFUToNetlist(), RFTestbenchGenerator::createTbInstantiation(), FUTestbenchGenerator::createTbInstantiation(), HDBToHtml::fuImplToHtml(), HWBlockImplementation(), HDBToHtml::rfImplToHtml(), and TestbenchGenerator::writeTestbench().
bool HDB::HWBlockImplementation::hasID | ( | ) | const |
Tells whether the implementation has an ID.
Definition at line 105 of file HWBlockImplementation.cc.
References hasID_.
Referenced by HDBEditorModifyCmd::Do(), HWBlockImplementation(), and id().
RowID HDB::HWBlockImplementation::id | ( | ) | const |
Returns the ID of the implementation.
Definition at line 128 of file HWBlockImplementation.cc.
References __func__, hasID(), and id_.
Referenced by HDBEditorModifyCmd::Do(), HDBToHtml::fuEntryToHtml(), HWBlockImplementation(), HDBToHtml::rfEntryToHtml(), setID(), and HDBBrowserWindow::update().
int HDB::HWBlockImplementation::implementationFileCount | ( | ) | const |
Returns the number of files which constitutes the implementation of the block.
Definition at line 254 of file HWBlockImplementation.cc.
References files_.
Referenced by HDB::HDBManager::addFUImplementation(), ImplementationTester::createListOfSimulationFiles(), file(), HDBToHtml::fuImplToHtml(), ProGeScriptGenerator::getBlockOrder(), HWBlockImplementation(), and HDBToHtml::rfImplToHtml().
std::string HDB::HWBlockImplementation::moduleName | ( | ) | const |
Returns the name of the module.
Definition at line 153 of file HWBlockImplementation.cc.
References moduleName_.
Referenced by HDB::HDBManager::addFUImplementation(), ProGe::NetlistGenerator::addFUToNetlist(), RFTestbenchGenerator::createTbInstantiation(), FUTestbenchGenerator::createTbInstantiation(), HDBToHtml::fuEntryToHtml(), HDBToHtml::fuImplToHtml(), HWBlockImplementation(), BlockImplementationDialog::onHDBSelection(), HDBToHtml::rfEntryToHtml(), HDBToHtml::rfImplToHtml(), and HDBBrowserWindow::update().
void HDB::HWBlockImplementation::removeImplementationFile | ( | const BlockImplementationFile & | file | ) |
Removes the given block implementation file from the implementation.
file | The file to remove. |
Definition at line 241 of file HWBlockImplementation.cc.
References file(), files_, and ContainerTools::removeValueIfExists().
std::string HDB::HWBlockImplementation::rstPort | ( | ) | const |
Returns the name of the reset port.
Definition at line 197 of file HWBlockImplementation.cc.
References rstPort_.
Referenced by HDB::HDBManager::addFUImplementation(), ProGe::NetlistGenerator::addFUToNetlist(), RFTestbenchGenerator::createTbInstantiation(), FUTestbenchGenerator::createTbInstantiation(), HDBToHtml::fuImplToHtml(), HWBlockImplementation(), HDBToHtml::rfImplToHtml(), and TestbenchGenerator::writeTestbench().
void HDB::HWBlockImplementation::setClkPort | ( | const std::string & | name | ) |
Sets the name of the clock port.
name | Name of the port. |
Definition at line 164 of file HWBlockImplementation.cc.
References clkPort_.
void HDB::HWBlockImplementation::setGlockPort | ( | const std::string & | name | ) |
Sets the name of the global lock port.
name | Name of the port. |
Definition at line 208 of file HWBlockImplementation.cc.
References glockPort_.
void HDB::HWBlockImplementation::setID | ( | RowID | id | ) |
void HDB::HWBlockImplementation::setModuleName | ( | const std::string & | name | ) |
Sets the module name.
name | Name of the module. |
Definition at line 142 of file HWBlockImplementation.cc.
References moduleName_.
void HDB::HWBlockImplementation::setRstPort | ( | const std::string & | name | ) |
Sets the name of the reset port.
name | Name of the port. |
Definition at line 186 of file HWBlockImplementation.cc.
References rstPort_.
|
private |
Name of the clock port.
Definition at line 87 of file HWBlockImplementation.hh.
Referenced by clkPort(), HWBlockImplementation(), and setClkPort().
|
private |
Contains the block implementation files.
Definition at line 93 of file HWBlockImplementation.hh.
Referenced by addImplementationFile(), file(), implementationFileCount(), removeImplementationFile(), and ~HWBlockImplementation().
|
private |
Name of the global lock port.
Definition at line 91 of file HWBlockImplementation.hh.
Referenced by glockPort(), HWBlockImplementation(), and setGlockPort().
|
private |
Tells whether the implementation has an ID.
Definition at line 95 of file HWBlockImplementation.hh.
Referenced by hasID(), HWBlockImplementation(), and setID().
|
private |
ID of the implementation.
Definition at line 98 of file HWBlockImplementation.hh.
Referenced by HWBlockImplementation(), id(), and setID().
|
private |
Name of the module.
Definition at line 85 of file HWBlockImplementation.hh.
Referenced by HWBlockImplementation(), moduleName(), and setModuleName().
|
private |
Name of the reset port.
Definition at line 89 of file HWBlockImplementation.hh.
Referenced by HWBlockImplementation(), rstPort(), and setRstPort().