]> AND Private Git Repository - blast.git/blob - VHDLConverter.h
Logo AND Algorithmique Numérique Distribuée

Private GIT Repository
changes in output pattern comput
[blast.git] / VHDLConverter.h
1 #ifndef __VHDLCONVERTER_H__\r
2 #define __VHDLCONVERTER_H__\r
3 \r
4 \r
5 #include <QtGui>\r
6 #include <QtWidgets>\r
7 #include <QtCore>\r
8 #include <QtXml>\r
9 #include <iostream>\r
10 #include <fstream>\r
11 #include <QTextStream>\r
12 \r
13 #include "Parameters.h"\r
14 #include "Exception.h"\r
15 #include "ReferenceBlock.h"\r
16 #include "IfacePurposeDelegate.h"\r
17 \r
18 class VHDLConverter : public QWidget {\r
19     Q_OBJECT\r
20 public:\r
21     explicit VHDLConverter(QWidget *parent = 0);\r
22     ~VHDLConverter();\r
23 \r
24 private:\r
25     QPushButton* loadBut;\r
26     QPushButton* genBut;\r
27 \r
28     // entity related\r
29     QString entityName;\r
30     QString longName;\r
31     QLineEdit* editEntityName;\r
32     QLineEdit* editLongName;\r
33 \r
34     // data ports related\r
35     QScrollArea *scrollPorts;\r
36     QTableWidget* twPorts;\r
37     IfacePurposeDelegate* purposeDelegate;\r
38     \r
39     // generics related\r
40     QScrollArea* scrollGenerics;    \r
41     QTableWidget* twGenerics;\r
42         \r
43     // arch related\r
44     QString archName;\r
45     QList<QString> archLines;\r
46     \r
47     // libraries related\r
48     QHash<QString,QList<QString>* > packages;        \r
49     \r
50     QTextEdit *teBrief, *teDesc;\r
51 \r
52     ReferenceBlock* block;\r
53 \r
54     QList<AbstractInterface*> lstIface;\r
55 \r
56     QString readLibraries(QTextStream& in) throw(Exception);\r
57     QString readEntity(QTextStream& in) throw(Exception);\r
58     void readGenerics(QTextStream& in) throw(Exception);\r
59     void readPorts(QTextStream& in) throw(Exception);\r
60     void readArchitecture(QTextStream& in) throw(Exception);\r
61     \r
62     QString skipBlankAndComments(QTextStream& in);\r
63 \r
64     void generateRefXml(QDomDocument& doc);\r
65     void generateImplXml(QDomDocument& doc);\r
66     void replaceSignalNames(QString& line);\r
67 \r
68     void updateArchitecture();\r
69 \r
70 signals:\r
71 \r
72 public slots:\r
73     void loadVHDLFile();\r
74     void generateXml();\r
75 \r
76 private slots:\r
77     void searchAssociatedPort(QTableWidgetItem* item);\r
78 };\r
79 \r
80 #endif // __VHDLCONVERTER_H__\r