\r
#include <QtCore>\r
\r
+#include "AbstractInterface.h"\r
class AbstractInterface;\r
class BlockParameter;\r
\r
QList<BlockParameter *> getPortParameters();\r
QList<BlockParameter *> getWishboneParameters();\r
inline AbstractBlock* getParent() { return parent; }\r
- inline QList<int> getProductionCounter() { return productionCounter; }\r
- inline int getDelta() { return delta; }\r
+ inline bool getPatternComputed() { return patternComputed; }\r
\r
// setters\r
void setName(const QString& str);\r
virtual void setParent(AbstractBlock* _parent);\r
- inline void setProductionCounter(QList<int> pattern) { productionCounter = pattern; }\r
- inline void setDelta(int _delta) { delta = _delta; }\r
+ inline void setPatternComputed(bool state) { patternComputed = state; }\r
\r
// testers\r
virtual bool isReferenceBlock();\r
void removeAllInterfaces();\r
void defineBlockParam(BlockParameter *param);\r
\r
- QList<AbstractInterface *> getInterfaces(); //! return all interfaces\r
+ QList<AbstractInterface *> getInterfaces(int direction = AbstractInterface::AnyDirection, int purpose = AbstractInterface::AnyPurpose);\r
QList<AbstractInterface *> getDataInputs(); //! return all inputs of type data\r
+ QList<AbstractInterface *> getDataOutputs(); //! return all inputs of type data\r
QList<AbstractInterface *> getControlInputs(); //! return all inputs of type control\r
QList<AbstractInterface *> getControlOutputs(); //! return all outputs of type control\r
AbstractInterface* getIfaceFromName(QString name);\r
BlockParameter* getParameterFromName(QString name);\r
\r
// patterns\r
- virtual void computeOutputPattern(int nbExec = -1) = 0;\r
+ virtual void checkInputPatternCompatibility() throw(Exception) = 0;\r
+ virtual void computeOutputPattern(int nbExec = -1) throw(Exception) = 0;\r
\r
protected:\r
\r
\r
// others\r
\r
- // patterns\r
- QList<int> productionCounter; //! only usefull for output interfaces\r
- int delta;\r
+ // patterns \r
+ bool patternComputed;\r
\r
// NB: only GroupBlock and FunctionalBlock have a real parent, except sources that have no parents\r
AbstractBlock* parent;\r