class GroupBlock;\r
class FunctionalBlock;\r
class GroupScene;\r
+class AbstractBoxItem;\r
class GroupItem;\r
class BoxItem;\r
class InterfaceItem;\r
class Graph;\r
+class GroupWidget;\r
\r
#include "BlockImplementation.h"\r
\r
using namespace std;\r
using namespace Qt;\r
\r
+/*!\r
+ * \brief The Parameters class\r
+ *\r
+ * Parameters class represents the Model part of blast in MVC paradigm.\r
+ * It contains all data necessary to create a design: the graph of blocks,\r
+ * the scenes, ...\r
+ */\r
class Parameters {\r
\r
public :\r
QList<QString> implPathes;\r
QList<ReferenceBlock*> availableBlocks;\r
QList<BlockImplementation*> availableImplementations;\r
-\r
+ ReferenceBlock* delayRef;\r
+ BlockImplementation* delayImpl; \r
\r
QString refLib;\r
QString implLib;\r
// defaults for vhdl\r
int wbDataWidth;\r
int wbAddressWidth;\r
+ QString validityExtension; //! the string to add to ports to obtain the name of the associated validity port.\r
+ \r
// defaults for scene elements\r
int defaultBlockWidth;\r
int defaultBlockHeight;\r
/***************************************************\r
attributes that are specific for the current project\r
****************************************************/\r
+ bool isCurrentProject; // true if a projet is currently open\r
int sceneMode; // takes values from MODE_XXX\r
CursorState cursorState;\r
EditState editState; // takes values from EDIT_STATE_XXX\r
bool unsaveModif;\r
bool isRstClkShown;\r
+ QMap<FunctionalBlock*, BoxItem*> blockToItem; // allow to retrieve a box item from a functionnal block\r
\r
Graph* createGraph();\r
void destroyGraph();\r
- inline Graph* getGraph() { return graph; }\r
- GroupBlock* addGroupBlock(); // adding an empty GroupBlock to the current group\r
- FunctionalBlock* addFunctionalBlock(int idCategory, int idBlock); // adding a functional block to current group\r
+ inline Graph* getGraph() { return graph; } \r
+ ReferenceBlock* getReferenceBlock(int idCategory, int idBlock); // get the reference block from its category and index\r
FunctionalBlock* duplicateFunctionalBlock(FunctionalBlock* block); // adding a copy of a functional block to current group\r
\r
\r
void clear();\r
\r
QDomElement openProjectFile(const QString& projectFileName) throw(Exception);\r
- void loadProject(QDomElement root);\r
+ GroupWidget *loadProject(QDomElement root) throw(Exception);\r
\r
void loadBlastConfiguration(QString confFile) throw(Exception);\r
void loadReferencesFromXml() throw(Exception);\r
void loadReferencesFromLib() throw(Exception);\r
void saveReferencesToLib() throw(Exception);\r
+ void createDelayBlock();\r
\r
void loadImplementationsFromXml() throw(Exception);\r
void loadImplementationsFromLib() throw(Exception);\r
ReferenceBlock* searchBlockByXml(QString xmlName);\r
ReferenceBlock* searchBlockByMd5(QString sumMd5);\r
\r
+ BoxItem* searchFunctionalBlock(AbstractBlock* block);\r
+\r
void save(QString confFile);\r
\r
\r
\r
GroupScene* searchSceneById(int id, GroupScene* scene);\r
BoxItem* searchBlockItemById(int id, GroupScene* scene);\r
+ BoxItem* searchFunctionalBlockRecur(AbstractBlock* block, GroupScene* scene);\r
GroupItem* searchGroupItemById(int id, GroupScene* scene);\r
InterfaceItem* searchInterfaceItemById(int id, GroupScene *scene);\r
\r