inline QList<int> getProductionCounter() { return productionCounter; }\r
inline QMap<AbstractInterface*, QList<char>* > getConsumptionPattern() { return consumptionPattern; }\r
inline QMap<AbstractInterface*, QList<char>* > getProductionPattern() { return productionPattern; }\r
+ inline QMap<AbstractInterface*, QList<int>* > getAdmittanceDelays() { return admittanceDelays; }\r
inline int getConsumptionPatternLength() { return lengthCP; }\r
inline int getProductionPatternLength() { return lengthPP; }\r
inline int getDelta() { return delta; }\r
void createPatterns() throw(Exception); // called in Graph, before checking compatibility and computing output pattern\r
void checkInputPatternCompatibility() throw(Exception);\r
void computeOutputPattern(int nbExec = -1) throw(Exception);\r
- \r
+ void computeAdmittanceDelays() throw(Exception); // compute differences between IP and admittance\r
+\r
private: \r
// patterns\r
void createDelta() throw(Exception);\r
void createProductionPattern() throw(Exception); // initialize a QList<char> for each interface from patterns defined in implementation\r
void createProductionCounter() throw(Exception); // initialize a QList<int> from counter defined in implementation\r
void createAdmittance(int nbExec) throw(Exception); // initialize a QList<char> from consumption pattern and delta\r
+\r
void clearConsumptionPattern();\r
void clearProductionPattern();\r
void createInputPattern() throw(Exception);\r
void clearInputPattern();\r
+ void clearAdmittanceDelays();\r
int createTriggers(); // compute the clock cycle at which the block is triggered\r
\r
double evaluateExpression(const QString& expression) throw(Exception);\r
QList<char>* expandPattern(const QString& patternIn) throw(Exception);\r
QList<char> expandPatternRecur(const QString& patternIn, int* offset) throw(Exception);\r
+ QString replaceExpressions(const QString& patternIn) throw(Exception);\r
/*!\r
* \brief samePatterns\r
* \param patternSrc the pattern that must be tested with patternDest (is patternDest == patternDest) \r
leaving the dest pattern in an inconsistent state. Thus, it is a good idea to call canCombine before.\r
*/\r
bool samePatterns(const QMap<AbstractInterface*, QList<char>* >& patternSrc, int srcCol, const QMap<AbstractInterface*, QList<char>* >& patternDest, int destCol);\r
+ bool samePatterns(const QMap<AbstractInterface*, QList<char>* >& patternSrc, const QList<int>& srcCols, const QMap<AbstractInterface*, QList<char>* >& patternDest, int destCol);\r
/*!\r
* \brief canCombinePatterns\r
* \param patternSrc the pattern that must be combined with patternDest (patternDest = patternDest OR patternSrc) \r
* isValidGroup checks if there is at least one 1 in the column offset of pattern.\r
*/\r
bool isValidDataGroup(const QMap<AbstractInterface*, QList<char>* >& pattern, int offset);\r
+ bool isValidDataGroup(const QMap<AbstractInterface*, QList<char>* >& pattern, const QList<int> offsets);\r
/*!\r
* \brief isOnlyXGroup\r
* \param pattern the pattern to test\r
void shiftRightPattern(const QMap<AbstractInterface*, QList<char>* >& pattern, int offset);\r
\r
QMap<AbstractInterface*, QList<char>* > consumptionPattern;\r
- QMap<AbstractInterface*, QString > admittanceCyclic; // the admittance expressed as prologue-cyclic part-eppilogue, deduced from admittance\r
+ QMap<AbstractInterface*, QString > admittanceCyclic; // the admittance expressed as prologue-cyclic part-epilogue, deduced from admittance\r
QMap<AbstractInterface*, QList<char>* > admittance; // the admittance taking into account nb exec.\r
+ QMap<AbstractInterface*, QList<int>* > admittanceDelays; // the delay between what should be consumed and IP\r
QMap<AbstractInterface*, QList<char>* > productionPattern;\r
QMap<AbstractInterface*,QList<char>* > inputPattern;\r
QMap<AbstractInterface*, QList<char>* > outputPattern; // CAUTION: the QList<char>* must also be stored in the outputPattern attributes of AbstractInterface\r