]> AND Private Git Repository - blast.git/blobdiff - InterfaceItem.cpp
Logo AND Algorithmique Numérique Distribuée

Private GIT Repository
finalized analysis with clkconvert + started testbench gen.
[blast.git] / InterfaceItem.cpp
index 02b04ac6aa3db045d593bab291c265bc715b301e..7ee68c628f967731aafc5b4e5f27f961ba89a908 100644 (file)
@@ -4,6 +4,7 @@
 #include "GroupInterface.h"
 #include "FunctionalInterface.h"
 #include "BoxItem.h"
+#include "ReferenceInterface.h"
 
 int InterfaceItem::counter = 0;
 
@@ -45,6 +46,15 @@ QString InterfaceItem::getName() {
   return refInter->getName();
 }
 
+QString InterfaceItem::getReferenceName() {
+  if (!refInter->isFunctionalInterface()) {
+    return "no_refname_for_groupiface";
+  }
+  FunctionalInterface* iface = AI_TO_FUN(refInter);
+  ReferenceInterface* refIface = iface->getReference();
+  return refIface->getName();
+}
+
 void InterfaceItem::updateName(QString name) {  
   QFontMetrics fmName(params->defaultIfaceFont);
   nameWidth = fmName.width(refInter->getName());