X-Git-Url: https://bilbo.iut-bm.univ-fcomte.fr/and/gitweb/blast.git/blobdiff_plain/dd274e84e0518f8c9ac0cacba2bc56e5be2985b1..6e2b3026c6a496e81642c373796bd39dad33d2a6:/AbstractBlock.cpp?ds=sidebyside diff --git a/AbstractBlock.cpp b/AbstractBlock.cpp index b78a1e1..3bb808e 100644 --- a/AbstractBlock.cpp +++ b/AbstractBlock.cpp @@ -285,9 +285,30 @@ void AbstractBlock::connectClkReset() throw(Exception) { fromClk->connectTo(toClk); fromRst->connectTo(toRst); } +} +void AbstractBlock::generateEntity(QTextStream& out, bool hasController) throw(Exception) { + out << "entity " << name << " is" << endl; + try { + generateEntityOrComponentBody(out, 0, hasController); + } + catch(Exception e) { + throw(e); + } + out << "end entity " << name << ";" << endl << endl; } +void AbstractBlock::generateComponent(QTextStream& out, bool hasController) throw(Exception) { + + out << " component " << name << " is" << endl; + try { + generateEntityOrComponentBody(out, 2, hasController); + } + catch(Exception e) { + throw(e); + } + out << " end component " << endl << endl; +}