HAL
v4.5.0-83-g30c8f0afc
The Hardware Analyzer - a comprehensive reverse engineering and manipulation framework for gate-level netlists.
gatelibrary_wizard.h
Go to the documentation of this file.
1
// MIT License
2
//
3
// Copyright (c) 2019 Ruhr University Bochum, Chair for Embedded Security. All Rights reserved.
4
// Copyright (c) 2019 Marc Fyrbiak, Sebastian Wallat, Max Hoffmann ("ORIGINAL AUTHORS"). All rights reserved.
5
// Copyright (c) 2021 Max Planck Institute for Security and Privacy. All Rights reserved.
6
// Copyright (c) 2021 Jörn Langheinrich, Julian Speith, Nils Albartus, René Walendy, Simon Klix ("ORIGINAL AUTHORS"). All Rights reserved.
7
//
8
// Permission is hereby granted, free of charge, to any person obtaining a copy
9
// of this software and associated documentation files (the "Software"), to deal
10
// in the Software without restriction, including without limitation the rights
11
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
12
// copies of the Software, and to permit persons to whom the Software is
13
// furnished to do so, subject to the following conditions:
14
//
15
// The above copyright notice and this permission notice shall be included in all
16
// copies or substantial portions of the Software.
17
//
18
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
21
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
23
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
24
// SOFTWARE.
25
26
#pragma once
27
#include "
hal_core/netlist/gate_library/gate_type.h
"
28
29
#include "
gui/gatelibrary_management/gatelibrary_pages/generalinfo_wizardpage.h
"
30
#include "
gui/gatelibrary_management/gatelibrary_pages/pins_wizardpage.h
"
31
#include "
gui/gatelibrary_management/gatelibrary_pages/flipflop_wizardpage.h
"
32
#include "
gui/gatelibrary_management/gatelibrary_pages/bool_wizardpage.h
"
33
#include "
gui/gatelibrary_management/gatelibrary_pages/latch_wizardpage.h
"
34
#include "
gui/gatelibrary_management/gatelibrary_pages/lut_wizardpage.h
"
35
#include "
gui/gatelibrary_management/gatelibrary_pages/init_wizardpage.h
"
36
#include "
gui/gatelibrary_management/gatelibrary_pages/ram_wizardpage.h
"
37
#include "
gui/gatelibrary_management/gatelibrary_pages/ram_port_wizardpage.h
"
38
#include "
gui/gatelibrary_management/gatelibrary_pages/state_wizardpage.h
"
39
40
41
#include <QWizard>
42
#include <QWizardPage>
43
44
namespace
hal
45
{
49
class
GateLibraryWizard
:
public
QWizard
50
{
51
Q_OBJECT
52
53
friend
class
GeneralInfoWizardPage
;
54
friend
class
PinsWizardPage
;
55
friend
class
FlipFlopWizardPage
;
56
friend
class
BoolWizardPage
;
57
friend
class
LatchWizardPage
;
58
59
friend
class
RAMPortWizardPage
;
60
friend
class
StateWizardPage
;
61
friend
class
InitWizardPage
;
62
public
:
63
enum
PAGE
64
{
65
GeneralInfo
,
66
Pin
,
67
FlipFlop
,
68
Latch
,
69
LUT
,
70
RAM
,
71
RAMPort
,
72
Init
,
73
State
,
74
BoolFunc
75
};
76
77
GateLibraryWizard
(
GateLibrary
* gateLibrary,
GateType
* gateType =
nullptr
,
QWidget
*
parent
=
nullptr
);
78
79
QList<PinItem*>
getPingroups
();
80
std::unique_ptr<GateTypeComponent>
setComponents
();
81
GateType
*
getRecentCreatedGate
();
82
void
accept
()
override
;
83
int
nextId
()
const override
;
84
Q_SIGNALS
:
85
void
triggerUnsavedChanges
();
86
private
Q_SLOTS
:
87
void
handleWasEdited();
88
private
:
89
GateLibrary
* mGateLibrary;
90
GateType
* mGateType;
91
GeneralInfoWizardPage
* generalInfoPage;
92
PinsWizardPage
* pinsPage;
93
FlipFlopWizardPage
* ffPage;
94
LatchWizardPage
* latchPage;
95
LUTWizardPage
* lutPage;
96
InitWizardPage
* initPage;
97
RAMWizardPage
* ramPage;
98
RAMPortWizardPage
* ramportPage;
99
StateWizardPage
* statePage;
100
BoolWizardPage
* boolPage;
101
102
PinModel
* mPinModel;
103
GateType
* mNewGateType;
104
bool
mWasEdited;
105
bool
mEditMode;
106
QString
mTitle;
107
};
108
}
bool_wizardpage.h
hal::BoolWizardPage
Definition:
bool_wizardpage.h:84
hal::FlipFlopWizardPage
Definition:
flipflop_wizardpage.h:42
hal::GateLibrary
Definition:
gate_library.h:44
hal::GateLibraryWizard
Definition:
gatelibrary_wizard.h:50
hal::GateLibraryWizard::triggerUnsavedChanges
void triggerUnsavedChanges()
hal::GateLibraryWizard::nextId
int nextId() const override
Definition:
gatelibrary_wizard.cpp:274
hal::GateLibraryWizard::getPingroups
QList< PinItem * > getPingroups()
Definition:
gatelibrary_wizard.cpp:154
hal::GateLibraryWizard::getRecentCreatedGate
GateType * getRecentCreatedGate()
Definition:
gatelibrary_wizard.cpp:150
hal::GateLibraryWizard::setComponents
std::unique_ptr< GateTypeComponent > setComponents()
Definition:
gatelibrary_wizard.cpp:159
hal::GateLibraryWizard::GateLibraryWizard
GateLibraryWizard(GateLibrary *gateLibrary, GateType *gateType=nullptr, QWidget *parent=nullptr)
Definition:
gatelibrary_wizard.cpp:20
hal::GateLibraryWizard::accept
void accept() override
Definition:
gatelibrary_wizard.cpp:85
hal::GateLibraryWizard::PAGE
PAGE
Definition:
gatelibrary_wizard.h:64
hal::GateLibraryWizard::GeneralInfo
@ GeneralInfo
Definition:
gatelibrary_wizard.h:65
hal::GateLibraryWizard::Latch
@ Latch
Definition:
gatelibrary_wizard.h:68
hal::GateLibraryWizard::FlipFlop
@ FlipFlop
Definition:
gatelibrary_wizard.h:67
hal::GateLibraryWizard::State
@ State
Definition:
gatelibrary_wizard.h:73
hal::GateLibraryWizard::Init
@ Init
Definition:
gatelibrary_wizard.h:72
hal::GateLibraryWizard::BoolFunc
@ BoolFunc
Definition:
gatelibrary_wizard.h:74
hal::GateLibraryWizard::Pin
@ Pin
Definition:
gatelibrary_wizard.h:66
hal::GateLibraryWizard::RAMPort
@ RAMPort
Definition:
gatelibrary_wizard.h:71
hal::GateLibraryWizard::LUT
@ LUT
Definition:
gatelibrary_wizard.h:69
hal::GateLibraryWizard::RAM
@ RAM
Definition:
gatelibrary_wizard.h:70
hal::GateType
Definition:
gate_type.h:52
hal::GeneralInfoWizardPage
Definition:
generalinfo_wizardpage.h:86
hal::InitWizardPage
Definition:
init_wizardpage.h:41
hal::LUTWizardPage
Definition:
lut_wizardpage.h:41
hal::LatchWizardPage
Definition:
latch_wizardpage.h:41
hal::PinModel
Definition:
pin_model.h:53
hal::PinsWizardPage
Definition:
pins_wizardpage.h:42
hal::RAMPortWizardPage
Definition:
ram_port_wizardpage.h:43
hal::RAMWizardPage
Definition:
ram_wizardpage.h:40
hal::StateWizardPage
Definition:
state_wizardpage.h:43
flipflop_wizardpage.h
gate_type.h
generalinfo_wizardpage.h
init_wizardpage.h
latch_wizardpage.h
lut_wizardpage.h
hal
Definition:
defines.h:45
pins_wizardpage.h
QList
QObject::Q_OBJECT
Q_OBJECTQ_OBJECT
QObject::Q_SIGNALS
Q_SIGNALSQ_SIGNALS
QObject::Q_SLOTS
Q_SLOTSQ_SLOTS
QObject::parent
QObject * parent() const const
QString
QWidget
QWizard
ram_port_wizardpage.h
ram_wizardpage.h
state_wizardpage.h
plugins
gui
include
gui
gatelibrary_management
gatelibrary_wizard.h
Generated by
1.9.1