LibrePCB Developers Documentation
componentcheckmessages.h
Go to the documentation of this file.
1/*
2 * LibrePCB - Professional EDA for everyone!
3 * Copyright (C) 2013 LibrePCB Developers, see AUTHORS.md for contributors.
4 * https://librepcb.org/
5 *
6 * This program is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation, either version 3 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
18 */
19
20#ifndef LIBREPCB_CORE_COMPONENTCHECKMESSAGES_H
21#define LIBREPCB_CORE_COMPONENTCHECKMESSAGES_H
22
23/*******************************************************************************
24 * Includes
25 ******************************************************************************/
26#include "../../rulecheck/rulecheckmessage.h"
27
28#include <QtCore>
29
30/*******************************************************************************
31 * Namespace / Forward Declarations
32 ******************************************************************************/
33namespace librepcb {
34
35class ComponentSignal;
36class ComponentSymbolVariant;
37
38/*******************************************************************************
39 * Class MsgDuplicateSignalName
40 ******************************************************************************/
41
46 Q_DECLARE_TR_FUNCTIONS(MsgDuplicateSignalName)
47
48public:
49 // Constructors / Destructor
51 explicit MsgDuplicateSignalName(const ComponentSignal& signal) noexcept;
53 : RuleCheckMessage(other) {}
54 virtual ~MsgDuplicateSignalName() noexcept {}
55};
56
57/*******************************************************************************
58 * Class MsgMissingComponentDefaultValue
59 ******************************************************************************/
60
65 Q_DECLARE_TR_FUNCTIONS(MsgMissingComponentDefaultValue)
66
67public:
68 // Constructors / Destructor
71 const MsgMissingComponentDefaultValue& other) noexcept
72 : RuleCheckMessage(other) {}
74};
75
76/*******************************************************************************
77 * Class MsgMissingComponentPrefix
78 ******************************************************************************/
79
84 Q_DECLARE_TR_FUNCTIONS(MsgMissingComponentPrefix)
85
86public:
87 // Constructors / Destructor
90 : RuleCheckMessage(other) {}
91 virtual ~MsgMissingComponentPrefix() noexcept {}
92};
93
94/*******************************************************************************
95 * Class MsgMissingSymbolVariant
96 ******************************************************************************/
97
102 Q_DECLARE_TR_FUNCTIONS(MsgMissingSymbolVariant)
103
104public:
105 // Constructors / Destructor
106 MsgMissingSymbolVariant() noexcept;
108 : RuleCheckMessage(other) {}
109 virtual ~MsgMissingSymbolVariant() noexcept {}
110};
111
112/*******************************************************************************
113 * Class MsgMissingSymbolVariantItem
114 ******************************************************************************/
115
120 Q_DECLARE_TR_FUNCTIONS(MsgMissingSymbolVariantItem)
121
122public:
123 // Constructors / Destructor
126 std::shared_ptr<const ComponentSymbolVariant> symbVar) noexcept;
128 : RuleCheckMessage(other), mSymbVar(other.mSymbVar) {}
129 virtual ~MsgMissingSymbolVariantItem() noexcept {}
130
131 // Getters
132 std::shared_ptr<const ComponentSymbolVariant> getSymbVar() const noexcept {
133 return mSymbVar;
134 }
135
136private:
137 std::shared_ptr<const ComponentSymbolVariant> mSymbVar;
138};
139
140/*******************************************************************************
141 * Class MsgNonFunctionalComponentSignalInversionSign
142 ******************************************************************************/
143
148 : public RuleCheckMessage {
150
151public:
152 // Constructors / Destructor
155 std::shared_ptr<const ComponentSignal> signal) noexcept;
158 : RuleCheckMessage(other), mSignal(other.mSignal) {}
160
161 // Getters
162 const std::shared_ptr<const ComponentSignal>& getSignal() const noexcept {
163 return mSignal;
164 }
165
166private:
167 std::shared_ptr<const ComponentSignal> mSignal;
168};
169
170/*******************************************************************************
171 * Class MsgNoPinsInSymbolVariantConnected
172 ******************************************************************************/
173
178 Q_DECLARE_TR_FUNCTIONS(MsgNoPinsInSymbolVariantConnected)
179
180public:
181 // Constructors / Destructor
184 std::shared_ptr<const ComponentSymbolVariant> symbVar) noexcept;
186 const MsgNoPinsInSymbolVariantConnected& other) noexcept
187 : RuleCheckMessage(other) {}
189
190 // Getters
191 std::shared_ptr<const ComponentSymbolVariant> getSymbVar() const noexcept {
192 return mSymbVar;
193 }
194
195private:
196 std::shared_ptr<const ComponentSymbolVariant> mSymbVar;
197};
198
199/*******************************************************************************
200 * End of File
201 ******************************************************************************/
202
203} // namespace librepcb
204
205#endif
The ComponentSignal class represents one signal of a component.
Definition: componentsignal.h:45
The MsgDuplicateSignalName class.
Definition: componentcheckmessages.h:45
MsgDuplicateSignalName(const MsgDuplicateSignalName &other) noexcept
Definition: componentcheckmessages.h:52
virtual ~MsgDuplicateSignalName() noexcept
Definition: componentcheckmessages.h:54
The MsgMissingComponentDefaultValue class.
Definition: componentcheckmessages.h:64
MsgMissingComponentDefaultValue(const MsgMissingComponentDefaultValue &other) noexcept
Definition: componentcheckmessages.h:70
virtual ~MsgMissingComponentDefaultValue() noexcept
Definition: componentcheckmessages.h:73
MsgMissingComponentDefaultValue() noexcept
Definition: componentcheckmessages.cpp:56
The MsgMissingComponentPrefix class.
Definition: componentcheckmessages.h:83
virtual ~MsgMissingComponentPrefix() noexcept
Definition: componentcheckmessages.h:91
MsgMissingComponentPrefix(const MsgMissingComponentPrefix &other) noexcept
Definition: componentcheckmessages.h:89
MsgMissingComponentPrefix() noexcept
Definition: componentcheckmessages.cpp:76
The MsgMissingSymbolVariant class.
Definition: componentcheckmessages.h:101
MsgMissingSymbolVariant(const MsgMissingSymbolVariant &other) noexcept
Definition: componentcheckmessages.h:107
MsgMissingSymbolVariant() noexcept
Definition: componentcheckmessages.cpp:90
virtual ~MsgMissingSymbolVariant() noexcept
Definition: componentcheckmessages.h:109
The MsgMissingSymbolVariantItem class.
Definition: componentcheckmessages.h:119
MsgMissingSymbolVariantItem(const MsgMissingSymbolVariantItem &other) noexcept
Definition: componentcheckmessages.h:127
virtual ~MsgMissingSymbolVariantItem() noexcept
Definition: componentcheckmessages.h:129
std::shared_ptr< const ComponentSymbolVariant > getSymbVar() const noexcept
Definition: componentcheckmessages.h:132
std::shared_ptr< const ComponentSymbolVariant > mSymbVar
Definition: componentcheckmessages.h:137
The MsgNoPinsInSymbolVariantConnected class.
Definition: componentcheckmessages.h:177
MsgNoPinsInSymbolVariantConnected(const MsgNoPinsInSymbolVariantConnected &other) noexcept
Definition: componentcheckmessages.h:185
virtual ~MsgNoPinsInSymbolVariantConnected() noexcept
Definition: componentcheckmessages.h:188
std::shared_ptr< const ComponentSymbolVariant > getSymbVar() const noexcept
Definition: componentcheckmessages.h:191
std::shared_ptr< const ComponentSymbolVariant > mSymbVar
Definition: componentcheckmessages.h:196
The MsgNonFunctionalComponentSignalInversionSign class.
Definition: componentcheckmessages.h:148
std::shared_ptr< const ComponentSignal > mSignal
Definition: componentcheckmessages.h:167
virtual ~MsgNonFunctionalComponentSignalInversionSign() noexcept
Definition: componentcheckmessages.h:159
MsgNonFunctionalComponentSignalInversionSign(const MsgNonFunctionalComponentSignalInversionSign &other) noexcept
Definition: componentcheckmessages.h:156
const std::shared_ptr< const ComponentSignal > & getSignal() const noexcept
Definition: componentcheckmessages.h:162
The RuleCheckMessage class.
Definition: rulecheckmessage.h:45
Definition: occmodel.cpp:77