+bool AbstractBlock::isTopGroupBlock() { \r
+ return false;\r
+}\r
+\r
+bool AbstractBlock::isStimuliBlock() {\r
+ return false;\r
+}\r
+/* NB: a source is a block that has no data inputs\r
+ * and has at least one data output.\r
+ * By the way, blocks that have no data input/output\r
+ * (like clkrstgen) are not sources !\r
+ */\r
+bool AbstractBlock::isSourceBlock() {\r
+ if (getDataInputs().size() > 0) return false;\r
+ if (getDataOutputs().size() == 0) return false;\r
+ return true;\r
+}\r
+\r
+/* NB: a sink is a block without outputs of any type */\r
+bool AbstractBlock::isSinkBlock() {\r
+ if (getOutputs().size() == 0) return true;\r
+ return false;\r
+}\r
+\r
+int AbstractBlock::getSpecialTypeFromString(QString str) {\r
+ if (str == "source") {\r
+ return Source;\r
+ }\r
+ else if (str == "sink") {\r
+ return Sink;\r
+ }\r
+ else if (str == "clkconvert") {\r
+ return ClkConvert;\r
+ }\r
+ return NotSpecial;\r
+}\r
+\r
+\r