LibrePCB Developers Documentation
packagecheckmessages.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_PACKAGECHECKMESSAGES_H
21 #define LIBREPCB_CORE_PACKAGECHECKMESSAGES_H
22 
23 /*******************************************************************************
24  * Includes
25  ******************************************************************************/
26 #include "../../rulecheck/rulecheckmessage.h"
27 #include "../../types/length.h"
28 
29 #include <QtCore>
30 
31 /*******************************************************************************
32  * Namespace / Forward Declarations
33  ******************************************************************************/
34 namespace librepcb {
35 
36 class Footprint;
37 class FootprintPad;
38 class Hole;
39 class Layer;
40 class PackagePad;
41 class Polygon;
42 class StrokeText;
43 class Zone;
44 
45 /*******************************************************************************
46  * Class MsgDeprecatedAssemblyType
47  ******************************************************************************/
48 
53  Q_DECLARE_TR_FUNCTIONS(MsgDeprecatedAssemblyType)
54 
55 public:
56  // Constructors / Destructor
57  MsgDeprecatedAssemblyType() noexcept;
59  : RuleCheckMessage(other) {}
60  virtual ~MsgDeprecatedAssemblyType() noexcept {}
61 };
62 
63 /*******************************************************************************
64  * Class MsgSuspiciousAssemblyType
65  ******************************************************************************/
66 
71  Q_DECLARE_TR_FUNCTIONS(MsgSuspiciousAssemblyType)
72 
73 public:
74  // Constructors / Destructor
75  MsgSuspiciousAssemblyType() noexcept;
77  : RuleCheckMessage(other) {}
78  virtual ~MsgSuspiciousAssemblyType() noexcept {}
79 };
80 
81 /*******************************************************************************
82  * Class MsgDuplicatePadName
83  ******************************************************************************/
84 
88 class MsgDuplicatePadName final : public RuleCheckMessage {
89  Q_DECLARE_TR_FUNCTIONS(MsgDuplicatePadName)
90 
91 public:
92  // Constructors / Destructor
93  MsgDuplicatePadName() = delete;
94  explicit MsgDuplicatePadName(const PackagePad& pad) noexcept;
96  : RuleCheckMessage(other) {}
97  virtual ~MsgDuplicatePadName() noexcept {}
98 };
99 
100 /*******************************************************************************
101  * Class MsgFiducialClearanceLessThanStopMask
102  ******************************************************************************/
103 
108  Q_DECLARE_TR_FUNCTIONS(MsgFiducialClearanceLessThanStopMask)
109 
110 public:
111  // Constructors / Destructor
114  std::shared_ptr<const Footprint> footprint,
115  std::shared_ptr<const FootprintPad> pad) noexcept;
117  const MsgFiducialClearanceLessThanStopMask& other) noexcept
118  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
120 
121  // Getters
122  std::shared_ptr<const Footprint> getFootprint() const noexcept {
123  return mFootprint;
124  }
125  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
126 
127 private:
128  std::shared_ptr<const Footprint> mFootprint;
129  std::shared_ptr<const FootprintPad> mPad;
130 };
131 
132 /*******************************************************************************
133  * Class MsgFiducialStopMaskNotSet
134  ******************************************************************************/
135 
140  Q_DECLARE_TR_FUNCTIONS(MsgFiducialStopMaskNotSet)
141 
142 public:
143  // Constructors / Destructor
144  MsgFiducialStopMaskNotSet() = delete;
145  MsgFiducialStopMaskNotSet(std::shared_ptr<const Footprint> footprint,
146  std::shared_ptr<const FootprintPad> pad) noexcept;
148  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
149  virtual ~MsgFiducialStopMaskNotSet() noexcept {}
150 
151  // Getters
152  std::shared_ptr<const Footprint> getFootprint() const noexcept {
153  return mFootprint;
154  }
155  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
156 
157 private:
158  std::shared_ptr<const Footprint> mFootprint;
159  std::shared_ptr<const FootprintPad> mPad;
160 };
161 
162 /*******************************************************************************
163  * Class MsgHoleWithoutStopMask
164  ******************************************************************************/
165 
170  Q_DECLARE_TR_FUNCTIONS(MsgHoleWithoutStopMask)
171 
172 public:
173  // Constructors / Destructor
174  MsgHoleWithoutStopMask() = delete;
175  MsgHoleWithoutStopMask(std::shared_ptr<const Footprint> footprint,
176  std::shared_ptr<const Hole> hole) noexcept;
178  : RuleCheckMessage(other),
179  mFootprint(other.mFootprint),
180  mHole(other.mHole) {}
181  virtual ~MsgHoleWithoutStopMask() noexcept {}
182 
183  // Getters
184  std::shared_ptr<const Footprint> getFootprint() const noexcept {
185  return mFootprint;
186  }
187  std::shared_ptr<const Hole> getHole() const noexcept { return mHole; }
188 
189 private:
190  std::shared_ptr<const Footprint> mFootprint;
191  std::shared_ptr<const Hole> mHole;
192 };
193 
194 /*******************************************************************************
195  * Class MsgInvalidCustomPadOutline
196  ******************************************************************************/
197 
202  Q_DECLARE_TR_FUNCTIONS(MsgInvalidCustomPadOutline)
203 
204 public:
205  // Constructors / Destructor
206  MsgInvalidCustomPadOutline() = delete;
207  MsgInvalidCustomPadOutline(std::shared_ptr<const Footprint> footprint,
208  std::shared_ptr<const FootprintPad> pad,
209  const QString& pkgPadName) noexcept;
211  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
212  virtual ~MsgInvalidCustomPadOutline() noexcept {}
213 
214  // Getters
215  std::shared_ptr<const Footprint> getFootprint() const noexcept {
216  return mFootprint;
217  }
218  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
219 
220 private:
221  std::shared_ptr<const Footprint> mFootprint;
222  std::shared_ptr<const FootprintPad> mPad;
223 };
224 
225 /*******************************************************************************
226  * Class MsgMissingCourtyard
227  ******************************************************************************/
228 
232 class MsgMissingCourtyard final : public RuleCheckMessage {
233  Q_DECLARE_TR_FUNCTIONS(MsgMissingCourtyard)
234 
235 public:
236  // Constructors / Destructor
237  MsgMissingCourtyard() = delete;
238  explicit MsgMissingCourtyard(
239  std::shared_ptr<const Footprint> footprint) noexcept;
241  : RuleCheckMessage(other) {}
242  virtual ~MsgMissingCourtyard() noexcept {}
243 
244  // Getters
245  std::shared_ptr<const Footprint> getFootprint() const noexcept {
246  return mFootprint;
247  }
248 
249 private:
250  std::shared_ptr<const Footprint> mFootprint;
251 };
252 
253 /*******************************************************************************
254  * Class MsgMissingFootprint
255  ******************************************************************************/
256 
260 class MsgMissingFootprint final : public RuleCheckMessage {
261  Q_DECLARE_TR_FUNCTIONS(MsgMissingFootprint)
262 
263 public:
264  // Constructors / Destructor
265  MsgMissingFootprint() noexcept;
267  : RuleCheckMessage(other) {}
268  virtual ~MsgMissingFootprint() noexcept {}
269 };
270 
271 /*******************************************************************************
272  * Class MsgMissingFootprintModel
273  ******************************************************************************/
274 
279  Q_DECLARE_TR_FUNCTIONS(MsgMissingFootprintModel)
280 
281 public:
282  // Constructors / Destructor
283  MsgMissingFootprintModel() = delete;
284  MsgMissingFootprintModel(std::shared_ptr<const Footprint> footprint) noexcept;
286  : RuleCheckMessage(other) {}
287  virtual ~MsgMissingFootprintModel() noexcept {}
288 };
289 
290 /*******************************************************************************
291  * Class MsgMissingFootprintName
292  ******************************************************************************/
293 
298  Q_DECLARE_TR_FUNCTIONS(MsgMissingFootprintName)
299 
300 public:
301  // Constructors / Destructor
302  MsgMissingFootprintName() = delete;
303  explicit MsgMissingFootprintName(
304  std::shared_ptr<const Footprint> footprint) noexcept;
306  : RuleCheckMessage(other) {}
307  virtual ~MsgMissingFootprintName() noexcept {}
308 
309  // Getters
310  std::shared_ptr<const Footprint> getFootprint() const noexcept {
311  return mFootprint;
312  }
313 
314 private:
315  std::shared_ptr<const Footprint> mFootprint;
316 };
317 
318 /*******************************************************************************
319  * Class MsgMissingFootprintValue
320  ******************************************************************************/
321 
326  Q_DECLARE_TR_FUNCTIONS(MsgMissingFootprintValue)
327 
328 public:
329  // Constructors / Destructor
330  MsgMissingFootprintValue() = delete;
331  explicit MsgMissingFootprintValue(
332  std::shared_ptr<const Footprint> footprint) noexcept;
334  : RuleCheckMessage(other) {}
335  virtual ~MsgMissingFootprintValue() noexcept {}
336 
337  // Getters
338  std::shared_ptr<const Footprint> getFootprint() const noexcept {
339  return mFootprint;
340  }
341 
342 private:
343  std::shared_ptr<const Footprint> mFootprint;
344 };
345 
346 /*******************************************************************************
347  * Class MsgMissingPackageOutline
348  ******************************************************************************/
349 
354  Q_DECLARE_TR_FUNCTIONS(MsgMissingPackageOutline)
355 
356 public:
357  // Constructors / Destructor
358  MsgMissingPackageOutline() = delete;
359  explicit MsgMissingPackageOutline(
360  std::shared_ptr<const Footprint> footprint) noexcept;
362  : RuleCheckMessage(other) {}
363  virtual ~MsgMissingPackageOutline() noexcept {}
364 
365  // Getters
366  std::shared_ptr<const Footprint> getFootprint() const noexcept {
367  return mFootprint;
368  }
369 
370 private:
371  std::shared_ptr<const Footprint> mFootprint;
372 };
373 
374 /*******************************************************************************
375  * Class MsgOverlappingPads
376  ******************************************************************************/
377 
381 class MsgOverlappingPads final : public RuleCheckMessage {
382  Q_DECLARE_TR_FUNCTIONS(MsgOverlappingPads)
383 
384 public:
385  // Constructors / Destructor
386  MsgOverlappingPads() = delete;
387  MsgOverlappingPads(std::shared_ptr<const Footprint> footprint,
388  std::shared_ptr<const FootprintPad> pad1,
389  const QString& pkgPad1Name,
390  std::shared_ptr<const FootprintPad> pad2,
391  const QString& pkgPad2Name) noexcept;
392  MsgOverlappingPads(const MsgOverlappingPads& other) noexcept
393  : RuleCheckMessage(other),
394  mFootprint(other.mFootprint),
395  mPad1(other.mPad1),
396  mPad2(other.mPad2) {}
397  virtual ~MsgOverlappingPads() noexcept {}
398 
399  // Getters
400  std::shared_ptr<const Footprint> getFootprint() const noexcept {
401  return mFootprint;
402  }
403  std::shared_ptr<const FootprintPad> getPad1() const noexcept { return mPad1; }
404  std::shared_ptr<const FootprintPad> getPad2() const noexcept { return mPad2; }
405 
406 private:
407  std::shared_ptr<const Footprint> mFootprint;
408  std::shared_ptr<const FootprintPad> mPad1;
409  std::shared_ptr<const FootprintPad> mPad2;
410 };
411 
412 /*******************************************************************************
413  * Class MsgPadAnnularRingViolation
414  ******************************************************************************/
415 
420  Q_DECLARE_TR_FUNCTIONS(MsgPadAnnularRingViolation)
421 
422 public:
423  // Constructors / Destructor
424  MsgPadAnnularRingViolation() = delete;
425  MsgPadAnnularRingViolation(std::shared_ptr<const Footprint> footprint,
426  std::shared_ptr<const FootprintPad> pad,
427  const QString& pkgPadName,
428  const Length& annularRing) noexcept;
430  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
431  virtual ~MsgPadAnnularRingViolation() noexcept {}
432 
433  // Getters
434  std::shared_ptr<const Footprint> getFootprint() const noexcept {
435  return mFootprint;
436  }
437  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
438 
439 private:
440  std::shared_ptr<const Footprint> mFootprint;
441  std::shared_ptr<const FootprintPad> mPad;
442 };
443 
444 /*******************************************************************************
445  * Class MsgPadClearanceViolation
446  ******************************************************************************/
447 
452  Q_DECLARE_TR_FUNCTIONS(MsgPadClearanceViolation)
453 
454 public:
455  // Constructors / Destructor
456  MsgPadClearanceViolation() = delete;
457  MsgPadClearanceViolation(std::shared_ptr<const Footprint> footprint,
458  std::shared_ptr<const FootprintPad> pad1,
459  const QString& pkgPad1Name,
460  std::shared_ptr<const FootprintPad> pad2,
461  const QString& pkgPad2Name,
462  const Length& clearance) noexcept;
464  : RuleCheckMessage(other),
465  mFootprint(other.mFootprint),
466  mPad1(other.mPad1),
467  mPad2(other.mPad2) {}
468  virtual ~MsgPadClearanceViolation() noexcept {}
469 
470  // Getters
471  std::shared_ptr<const Footprint> getFootprint() const noexcept {
472  return mFootprint;
473  }
474  std::shared_ptr<const FootprintPad> getPad1() const noexcept { return mPad1; }
475  std::shared_ptr<const FootprintPad> getPad2() const noexcept { return mPad2; }
476 
477 private:
478  std::shared_ptr<const Footprint> mFootprint;
479  std::shared_ptr<const FootprintPad> mPad1;
480  std::shared_ptr<const FootprintPad> mPad2;
481 };
482 
483 /*******************************************************************************
484  * Class MsgPadHoleOutsideCopper
485  ******************************************************************************/
486 
491  Q_DECLARE_TR_FUNCTIONS(MsgPadHoleOutsideCopper)
492 
493 public:
494  // Constructors / Destructor
495  MsgPadHoleOutsideCopper() = delete;
496  MsgPadHoleOutsideCopper(std::shared_ptr<const Footprint> footprint,
497  std::shared_ptr<const FootprintPad> pad,
498  const QString& pkgPadName) noexcept;
500  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
501  virtual ~MsgPadHoleOutsideCopper() noexcept {}
502 
503  // Getters
504  std::shared_ptr<const Footprint> getFootprint() const noexcept {
505  return mFootprint;
506  }
507  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
508 
509 private:
510  std::shared_ptr<const Footprint> mFootprint;
511  std::shared_ptr<const FootprintPad> mPad;
512 };
513 
514 /*******************************************************************************
515  * Class MsgPadOriginOutsideCopper
516  ******************************************************************************/
517 
522  Q_DECLARE_TR_FUNCTIONS(MsgPadOriginOutsideCopper)
523 
524 public:
525  // Constructors / Destructor
526  MsgPadOriginOutsideCopper() = delete;
527  MsgPadOriginOutsideCopper(std::shared_ptr<const Footprint> footprint,
528  std::shared_ptr<const FootprintPad> pad,
529  const QString& pkgPadName) noexcept;
531  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
532  virtual ~MsgPadOriginOutsideCopper() noexcept {}
533 
534  // Getters
535  std::shared_ptr<const Footprint> getFootprint() const noexcept {
536  return mFootprint;
537  }
538  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
539 
540 private:
541  std::shared_ptr<const Footprint> mFootprint;
542  std::shared_ptr<const FootprintPad> mPad;
543 };
544 
545 /*******************************************************************************
546  * Class MsgPadOverlapsWithLegend
547  ******************************************************************************/
548 
553  Q_DECLARE_TR_FUNCTIONS(MsgPadOverlapsWithLegend)
554 
555 public:
556  // Constructors / Destructor
557  MsgPadOverlapsWithLegend() = delete;
558  MsgPadOverlapsWithLegend(std::shared_ptr<const Footprint> footprint,
559  std::shared_ptr<const FootprintPad> pad,
560  const QString& pkgPadName,
561  const Length& clearance) noexcept;
563  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
564  virtual ~MsgPadOverlapsWithLegend() noexcept {}
565 
566  // Getters
567  std::shared_ptr<const Footprint> getFootprint() const noexcept {
568  return mFootprint;
569  }
570  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
571 
572 private:
573  std::shared_ptr<const Footprint> mFootprint;
574  std::shared_ptr<const FootprintPad> mPad;
575 };
576 
577 /*******************************************************************************
578  * Class MsgPadStopMaskOff
579  ******************************************************************************/
580 
584 class MsgPadStopMaskOff final : public RuleCheckMessage {
585  Q_DECLARE_TR_FUNCTIONS(MsgPadStopMaskOff)
586 
587 public:
588  // Constructors / Destructor
589  MsgPadStopMaskOff() = delete;
590  MsgPadStopMaskOff(std::shared_ptr<const Footprint> footprint,
591  std::shared_ptr<const FootprintPad> pad,
592  const QString& pkgPadName) noexcept;
593  MsgPadStopMaskOff(const MsgPadStopMaskOff& other) noexcept
594  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
595  virtual ~MsgPadStopMaskOff() noexcept {}
596 
597  // Getters
598  std::shared_ptr<const Footprint> getFootprint() const noexcept {
599  return mFootprint;
600  }
601  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
602 
603 private:
604  std::shared_ptr<const Footprint> mFootprint;
605  std::shared_ptr<const FootprintPad> mPad;
606 };
607 
608 /*******************************************************************************
609  * Class MsgPadWithCopperClearance
610  ******************************************************************************/
611 
616  Q_DECLARE_TR_FUNCTIONS(MsgPadWithCopperClearance)
617 
618 public:
619  // Constructors / Destructor
620  MsgPadWithCopperClearance() = delete;
621  MsgPadWithCopperClearance(std::shared_ptr<const Footprint> footprint,
622  std::shared_ptr<const FootprintPad> pad,
623  const QString& pkgPadName) noexcept;
625  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
626  virtual ~MsgPadWithCopperClearance() noexcept {}
627 
628  // Getters
629  std::shared_ptr<const Footprint> getFootprint() const noexcept {
630  return mFootprint;
631  }
632  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
633 
634 private:
635  std::shared_ptr<const Footprint> mFootprint;
636  std::shared_ptr<const FootprintPad> mPad;
637 };
638 
639 /*******************************************************************************
640  * Class MsgSmtPadWithSolderPaste
641  ******************************************************************************/
642 
647  Q_DECLARE_TR_FUNCTIONS(MsgSmtPadWithSolderPaste)
648 
649 public:
650  // Constructors / Destructor
651  MsgSmtPadWithSolderPaste() = delete;
652  MsgSmtPadWithSolderPaste(std::shared_ptr<const Footprint> footprint,
653  std::shared_ptr<const FootprintPad> pad,
654  const QString& pkgPadName) noexcept;
656  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
657  virtual ~MsgSmtPadWithSolderPaste() noexcept {}
658 
659  // Getters
660  std::shared_ptr<const Footprint> getFootprint() const noexcept {
661  return mFootprint;
662  }
663  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
664 
665 private:
666  std::shared_ptr<const Footprint> mFootprint;
667  std::shared_ptr<const FootprintPad> mPad;
668 };
669 
670 /*******************************************************************************
671  * Class MsgSmtPadWithoutSolderPaste
672  ******************************************************************************/
673 
678  Q_DECLARE_TR_FUNCTIONS(MsgSmtPadWithoutSolderPaste)
679 
680 public:
681  // Constructors / Destructor
682  MsgSmtPadWithoutSolderPaste() = delete;
683  MsgSmtPadWithoutSolderPaste(std::shared_ptr<const Footprint> footprint,
684  std::shared_ptr<const FootprintPad> pad,
685  const QString& pkgPadName) noexcept;
687  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
688  virtual ~MsgSmtPadWithoutSolderPaste() noexcept {}
689 
690  // Getters
691  std::shared_ptr<const Footprint> getFootprint() const noexcept {
692  return mFootprint;
693  }
694  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
695 
696 private:
697  std::shared_ptr<const Footprint> mFootprint;
698  std::shared_ptr<const FootprintPad> mPad;
699 };
700 
701 /*******************************************************************************
702  * Class MsgSuspiciousPadFunction
703  ******************************************************************************/
704 
709  Q_DECLARE_TR_FUNCTIONS(MsgSuspiciousPadFunction)
710 
711 public:
712  // Constructors / Destructor
713  MsgSuspiciousPadFunction(std::shared_ptr<const Footprint> footprint,
714  std::shared_ptr<const FootprintPad> pad,
715  const QString& pkgPadName) noexcept;
717  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
718  virtual ~MsgSuspiciousPadFunction() noexcept {}
719 
720  // Getters
721  std::shared_ptr<const Footprint> getFootprint() const noexcept {
722  return mFootprint;
723  }
724  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
725 
726 private:
727  std::shared_ptr<const Footprint> mFootprint;
728  std::shared_ptr<const FootprintPad> mPad;
729 };
730 
731 /*******************************************************************************
732  * Class MsgThtPadWithSolderPaste
733  ******************************************************************************/
734 
739  Q_DECLARE_TR_FUNCTIONS(MsgThtPadWithSolderPaste)
740 
741 public:
742  // Constructors / Destructor
743  MsgThtPadWithSolderPaste() = delete;
744  MsgThtPadWithSolderPaste(std::shared_ptr<const Footprint> footprint,
745  std::shared_ptr<const FootprintPad> pad,
746  const QString& pkgPadName) noexcept;
748  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
749  virtual ~MsgThtPadWithSolderPaste() noexcept {}
750 
751  // Getters
752  std::shared_ptr<const Footprint> getFootprint() const noexcept {
753  return mFootprint;
754  }
755  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
756 
757 private:
758  std::shared_ptr<const Footprint> mFootprint;
759  std::shared_ptr<const FootprintPad> mPad;
760 };
761 
762 /*******************************************************************************
763  * Class MsgUnspecifiedPadFunction
764  ******************************************************************************/
765 
770  Q_DECLARE_TR_FUNCTIONS(MsgUnspecifiedPadFunction)
771 
772 public:
773  // Constructors / Destructor
774  MsgUnspecifiedPadFunction(std::shared_ptr<const Footprint> footprint,
775  std::shared_ptr<const FootprintPad> pad,
776  const QString& pkgPadName) noexcept;
778  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
779  virtual ~MsgUnspecifiedPadFunction() noexcept {}
780 
781  // Getters
782  std::shared_ptr<const Footprint> getFootprint() const noexcept {
783  return mFootprint;
784  }
785  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
786 
787 private:
788  std::shared_ptr<const Footprint> mFootprint;
789  std::shared_ptr<const FootprintPad> mPad;
790 };
791 
792 /*******************************************************************************
793  * Class MsgUnusedCustomPadOutline
794  ******************************************************************************/
795 
800  Q_DECLARE_TR_FUNCTIONS(MsgUnusedCustomPadOutline)
801 
802 public:
803  // Constructors / Destructor
804  MsgUnusedCustomPadOutline() = delete;
805  MsgUnusedCustomPadOutline(std::shared_ptr<const Footprint> footprint,
806  std::shared_ptr<const FootprintPad> pad,
807  const QString& pkgPadName) noexcept;
809  : RuleCheckMessage(other), mFootprint(other.mFootprint), mPad(other.mPad) {}
810  virtual ~MsgUnusedCustomPadOutline() noexcept {}
811 
812  // Getters
813  std::shared_ptr<const Footprint> getFootprint() const noexcept {
814  return mFootprint;
815  }
816  std::shared_ptr<const FootprintPad> getPad() const noexcept { return mPad; }
817 
818 private:
819  std::shared_ptr<const Footprint> mFootprint;
820  std::shared_ptr<const FootprintPad> mPad;
821 };
822 
823 /*******************************************************************************
824  * Class MsgUselessZone
825  ******************************************************************************/
826 
830 class MsgUselessZone final : public RuleCheckMessage {
831  Q_DECLARE_TR_FUNCTIONS(MsgUselessZone)
832 
833 public:
834  // Constructors / Destructor
835  MsgUselessZone() = delete;
836  MsgUselessZone(std::shared_ptr<const Footprint> footprint,
837  std::shared_ptr<const Zone> zone) noexcept;
838  MsgUselessZone(const MsgUselessZone& other) noexcept
839  : RuleCheckMessage(other),
840  mFootprint(other.mFootprint),
841  mZone(other.mZone) {}
842  virtual ~MsgUselessZone() noexcept {}
843 
844  // Getters
845  std::shared_ptr<const Footprint> getFootprint() const noexcept {
846  return mFootprint;
847  }
848  std::shared_ptr<const Zone> getZone() const noexcept { return mZone; }
849 
850 private:
851  std::shared_ptr<const Footprint> mFootprint;
852  std::shared_ptr<const Zone> mZone;
853 };
854 
855 /*******************************************************************************
856  * Class MsgWrongFootprintTextLayer
857  ******************************************************************************/
858 
863  Q_DECLARE_TR_FUNCTIONS(MsgWrongFootprintTextLayer)
864 
865 public:
866  // Constructors / Destructor
867  MsgWrongFootprintTextLayer() = delete;
868  MsgWrongFootprintTextLayer(std::shared_ptr<const Footprint> footprint,
869  std::shared_ptr<const StrokeText> text,
870  const Layer& expectedLayer) noexcept;
872  : RuleCheckMessage(other),
873  mFootprint(other.mFootprint),
874  mText(other.mText),
875  mExpectedLayer(other.mExpectedLayer) {}
876  virtual ~MsgWrongFootprintTextLayer() noexcept {}
877 
878  // Getters
879  std::shared_ptr<const Footprint> getFootprint() const noexcept {
880  return mFootprint;
881  }
882  std::shared_ptr<const StrokeText> getText() const noexcept { return mText; }
883  const Layer& getExpectedLayer() const noexcept { return *mExpectedLayer; }
884 
885 private:
886  std::shared_ptr<const Footprint> mFootprint;
887  std::shared_ptr<const StrokeText> mText;
889 };
890 
891 /*******************************************************************************
892  * End of File
893  ******************************************************************************/
894 
895 } // namespace librepcb
896 
897 #endif
std::shared_ptr< const Hole > getHole() const noexcept
Definition: packagecheckmessages.h:187
The MsgSmtPadWithoutSolderPaste class.
Definition: packagecheckmessages.h:677
virtual ~MsgFiducialClearanceLessThanStopMask() noexcept
Definition: packagecheckmessages.h:119
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:400
MsgMissingPackageOutline(const MsgMissingPackageOutline &other) noexcept
Definition: packagecheckmessages.h:361
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:598
virtual ~MsgThtPadWithSolderPaste() noexcept
Definition: packagecheckmessages.h:749
MsgThtPadWithSolderPaste(const MsgThtPadWithSolderPaste &other) noexcept
Definition: packagecheckmessages.h:747
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:727
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:691
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:437
The MsgMissingFootprintValue class.
Definition: packagecheckmessages.h:325
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:788
The MsgSuspiciousAssemblyType class.
Definition: packagecheckmessages.h:70
The MsgFiducialClearanceLessThanStopMask class.
Definition: packagecheckmessages.h:107
The MsgOverlappingPads class.
Definition: packagecheckmessages.h:381
MsgHoleWithoutStopMask(const MsgHoleWithoutStopMask &other) noexcept
Definition: packagecheckmessages.h:177
virtual ~MsgUnusedCustomPadOutline() noexcept
Definition: packagecheckmessages.h:810
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:845
The MsgPadStopMaskOff class.
Definition: packagecheckmessages.h:584
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:667
The MsgUnusedCustomPadOutline class.
Definition: packagecheckmessages.h:799
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:635
virtual ~MsgSmtPadWithoutSolderPaste() noexcept
Definition: packagecheckmessages.h:688
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:636
MsgPadAnnularRingViolation(const MsgPadAnnularRingViolation &other) noexcept
Definition: packagecheckmessages.h:429
MsgMissingFootprintValue(const MsgMissingFootprintValue &other) noexcept
Definition: packagecheckmessages.h:333
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:440
The PackagePad class represents one logical pad of a package.
Definition: packagepad.h:47
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:190
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:785
std::shared_ptr< const FootprintPad > getPad2() const noexcept
Definition: packagecheckmessages.h:475
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:152
The MsgPadClearanceViolation class.
Definition: packagecheckmessages.h:451
MsgPadHoleOutsideCopper(const MsgPadHoleOutsideCopper &other) noexcept
Definition: packagecheckmessages.h:499
The MsgInvalidCustomPadOutline class.
Definition: packagecheckmessages.h:201
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:434
The MsgHoleWithoutStopMask class.
Definition: packagecheckmessages.h:169
const Layer * mExpectedLayer
Definition: packagecheckmessages.h:888
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:724
Definition: occmodel.cpp:76
MsgOverlappingPads(const MsgOverlappingPads &other) noexcept
Definition: packagecheckmessages.h:392
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:215
MsgPadClearanceViolation(const MsgPadClearanceViolation &other) noexcept
Definition: packagecheckmessages.h:463
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:504
The MsgDeprecatedAssemblyType class.
Definition: packagecheckmessages.h:52
The MsgThtPadWithSolderPaste class.
Definition: packagecheckmessages.h:738
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:510
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:366
virtual ~MsgUnspecifiedPadFunction() noexcept
Definition: packagecheckmessages.h:779
The Layer class provides all supported geometry layers.
Definition: layer.h:40
MsgMissingFootprintModel(const MsgMissingFootprintModel &other) noexcept
Definition: packagecheckmessages.h:285
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:752
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:573
MsgFiducialClearanceLessThanStopMask(const MsgFiducialClearanceLessThanStopMask &other) noexcept
Definition: packagecheckmessages.h:116
virtual ~MsgInvalidCustomPadOutline() noexcept
Definition: packagecheckmessages.h:212
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:129
The MsgMissingFootprintName class.
Definition: packagecheckmessages.h:297
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:441
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:886
The MsgPadHoleOutsideCopper class.
Definition: packagecheckmessages.h:490
virtual ~MsgSuspiciousPadFunction() noexcept
Definition: packagecheckmessages.h:718
The MsgMissingFootprint class.
Definition: packagecheckmessages.h:260
virtual ~MsgPadOverlapsWithLegend() noexcept
Definition: packagecheckmessages.h:564
MsgSmtPadWithSolderPaste(const MsgSmtPadWithSolderPaste &other) noexcept
Definition: packagecheckmessages.h:655
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:507
std::shared_ptr< const Zone > mZone
Definition: packagecheckmessages.h:852
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:535
MsgUselessZone(const MsgUselessZone &other) noexcept
Definition: packagecheckmessages.h:838
virtual ~MsgMissingFootprintModel() noexcept
Definition: packagecheckmessages.h:287
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:601
virtual ~MsgDeprecatedAssemblyType() noexcept
Definition: packagecheckmessages.h:60
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:758
std::shared_ptr< const FootprintPad > getPad2() const noexcept
Definition: packagecheckmessages.h:404
The MsgUnspecifiedPadFunction class.
Definition: packagecheckmessages.h:769
MsgMissingFootprint(const MsgMissingFootprint &other) noexcept
Definition: packagecheckmessages.h:266
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:125
virtual ~MsgMissingFootprintName() noexcept
Definition: packagecheckmessages.h:307
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:629
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:158
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:478
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:184
virtual ~MsgPadOriginOutsideCopper() noexcept
Definition: packagecheckmessages.h:532
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:789
virtual ~MsgPadClearanceViolation() noexcept
Definition: packagecheckmessages.h:468
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:250
virtual ~MsgDuplicatePadName() noexcept
Definition: packagecheckmessages.h:97
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:222
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:511
virtual ~MsgHoleWithoutStopMask() noexcept
Definition: packagecheckmessages.h:181
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:820
The MsgUselessZone class.
Definition: packagecheckmessages.h:830
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:567
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:407
virtual ~MsgPadWithCopperClearance() noexcept
Definition: packagecheckmessages.h:626
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:338
MsgUnspecifiedPadFunction(const MsgUnspecifiedPadFunction &other) noexcept
Definition: packagecheckmessages.h:777
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:698
MsgUnusedCustomPadOutline(const MsgUnusedCustomPadOutline &other) noexcept
Definition: packagecheckmessages.h:808
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:310
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:816
virtual ~MsgWrongFootprintTextLayer() noexcept
Definition: packagecheckmessages.h:876
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:879
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:755
virtual ~MsgPadStopMaskOff() noexcept
Definition: packagecheckmessages.h:595
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:694
The MsgPadWithCopperClearance class.
Definition: packagecheckmessages.h:615
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:574
std::shared_ptr< const FootprintPad > mPad1
Definition: packagecheckmessages.h:479
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:570
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:660
virtual ~MsgOverlappingPads() noexcept
Definition: packagecheckmessages.h:397
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:813
const Layer & getExpectedLayer() const noexcept
Definition: packagecheckmessages.h:883
virtual ~MsgMissingPackageOutline() noexcept
Definition: packagecheckmessages.h:363
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:122
MsgDeprecatedAssemblyType() noexcept
Definition: packagecheckmessages.cpp:39
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:697
std::shared_ptr< const FootprintPad > mPad2
Definition: packagecheckmessages.h:409
MsgSuspiciousAssemblyType(const MsgSuspiciousAssemblyType &other) noexcept
Definition: packagecheckmessages.h:76
The MsgPadOriginOutsideCopper class.
Definition: packagecheckmessages.h:521
The MsgFiducialStopMaskNotSet class.
Definition: packagecheckmessages.h:139
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:819
virtual ~MsgMissingCourtyard() noexcept
Definition: packagecheckmessages.h:242
MsgFiducialStopMaskNotSet(const MsgFiducialStopMaskNotSet &other) noexcept
Definition: packagecheckmessages.h:147
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:155
MsgMissingCourtyard(const MsgMissingCourtyard &other) noexcept
Definition: packagecheckmessages.h:240
virtual ~MsgPadAnnularRingViolation() noexcept
Definition: packagecheckmessages.h:431
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:666
MsgSuspiciousPadFunction(const MsgSuspiciousPadFunction &other) noexcept
Definition: packagecheckmessages.h:716
The MsgDuplicatePadName class.
Definition: packagecheckmessages.h:88
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:541
virtual ~MsgSuspiciousAssemblyType() noexcept
Definition: packagecheckmessages.h:78
virtual ~MsgMissingFootprintValue() noexcept
Definition: packagecheckmessages.h:335
The MsgSmtPadWithSolderPaste class.
Definition: packagecheckmessages.h:646
MsgDuplicatePadName(const MsgDuplicatePadName &other) noexcept
Definition: packagecheckmessages.h:95
std::shared_ptr< const FootprintPad > mPad1
Definition: packagecheckmessages.h:408
std::shared_ptr< const StrokeText > mText
Definition: packagecheckmessages.h:887
The MsgWrongFootprintTextLayer class.
Definition: packagecheckmessages.h:862
MsgPadStopMaskOff(const MsgPadStopMaskOff &other) noexcept
Definition: packagecheckmessages.h:593
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:851
MsgWrongFootprintTextLayer(const MsgWrongFootprintTextLayer &other) noexcept
Definition: packagecheckmessages.h:871
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:759
std::shared_ptr< const StrokeText > getText() const noexcept
Definition: packagecheckmessages.h:882
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:221
virtual ~MsgPadHoleOutsideCopper() noexcept
Definition: packagecheckmessages.h:501
std::shared_ptr< const FootprintPad > getPad1() const noexcept
Definition: packagecheckmessages.h:403
The RuleCheckMessage class.
Definition: rulecheckmessage.h:45
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:604
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:632
std::shared_ptr< const FootprintPad > mPad2
Definition: packagecheckmessages.h:480
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:721
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:663
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:128
The MsgPadOverlapsWithLegend class.
Definition: packagecheckmessages.h:552
The MsgSuspiciousPadFunction class.
Definition: packagecheckmessages.h:708
MsgPadWithCopperClearance(const MsgPadWithCopperClearance &other) noexcept
Definition: packagecheckmessages.h:624
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:782
MsgDeprecatedAssemblyType(const MsgDeprecatedAssemblyType &other) noexcept
Definition: packagecheckmessages.h:58
MsgPadOriginOutsideCopper(const MsgPadOriginOutsideCopper &other) noexcept
Definition: packagecheckmessages.h:530
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:218
MsgInvalidCustomPadOutline(const MsgInvalidCustomPadOutline &other) noexcept
Definition: packagecheckmessages.h:210
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:315
The Length class is used to represent a length (for example 12.75 millimeters)
Definition: length.h:82
std::shared_ptr< const FootprintPad > getPad() const noexcept
Definition: packagecheckmessages.h:538
MsgMissingFootprintName(const MsgMissingFootprintName &other) noexcept
Definition: packagecheckmessages.h:305
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:471
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:159
std::shared_ptr< const FootprintPad > getPad1() const noexcept
Definition: packagecheckmessages.h:474
MsgPadOverlapsWithLegend(const MsgPadOverlapsWithLegend &other) noexcept
Definition: packagecheckmessages.h:562
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:343
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:542
MsgSmtPadWithoutSolderPaste(const MsgSmtPadWithoutSolderPaste &other) noexcept
Definition: packagecheckmessages.h:686
The MsgPadAnnularRingViolation class.
Definition: packagecheckmessages.h:419
std::shared_ptr< const Footprint > getFootprint() const noexcept
Definition: packagecheckmessages.h:245
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:728
virtual ~MsgSmtPadWithSolderPaste() noexcept
Definition: packagecheckmessages.h:657
virtual ~MsgMissingFootprint() noexcept
Definition: packagecheckmessages.h:268
std::shared_ptr< const Hole > mHole
Definition: packagecheckmessages.h:191
The MsgMissingPackageOutline class.
Definition: packagecheckmessages.h:353
std::shared_ptr< const FootprintPad > mPad
Definition: packagecheckmessages.h:605
std::shared_ptr< const Footprint > mFootprint
Definition: packagecheckmessages.h:371
virtual ~MsgUselessZone() noexcept
Definition: packagecheckmessages.h:842
virtual ~MsgFiducialStopMaskNotSet() noexcept
Definition: packagecheckmessages.h:149
The MsgMissingFootprintModel class.
Definition: packagecheckmessages.h:278
The MsgMissingCourtyard class.
Definition: packagecheckmessages.h:232
std::shared_ptr< const Zone > getZone() const noexcept
Definition: packagecheckmessages.h:848