KiCad PCB EDA Suite
collectors.cpp
Go to the documentation of this file.
1 /*
2  * This program source code file is part of KiCad, a free EDA CAD application.
3  *
4  * Copyright (C) 2007-2008 SoftPLC Corporation, Dick Hollenbeck <dick@softplc.com>
5  * Copyright (C) 2004-2018 KiCad Developers, see AUTHORS.txt for contributors.
6  *
7  * This program is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License
9  * as published by the Free Software Foundation; either version 2
10  * of the License, or (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, you may find one here:
19  * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
20  * or you may search the http://www.gnu.org website for the version 2 license,
21  * or you may write to the Free Software Foundation, Inc.,
22  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
23  */
24 
25 #include <collectors.h>
26 #include <class_board_item.h> // class BOARD_ITEM
27 
28 #include <class_module.h>
29 #include <class_pad.h>
30 #include <class_track.h>
31 #include <class_marker_pcb.h>
32 #include <class_zone.h>
33 
34 
35 /* This module contains out of line member functions for classes given in
36  * collectors.h. Those classes augment the functionality of class PCB_EDIT_FRAME.
37  */
38 
39 
41  // there are some restrictions on the order of items in the general case.
42  // all items in m_Drawings for instance should be contiguous.
43  // *** all items in a same list (shown here) must be contiguous ****
44  PCB_MARKER_T, // in m_markers
45  PCB_TEXT_T, // in m_Drawings
46  PCB_LINE_T, // in m_Drawings
47  PCB_DIMENSION_T, // in m_Drawings
48  PCB_TARGET_T, // in m_Drawings
49  PCB_VIA_T, // in m_Tracks
50  PCB_TRACE_T, // in m_Tracks
51  PCB_PAD_T, // in modules
52  PCB_MODULE_TEXT_T, // in modules
53  PCB_MODULE_T, // in m_Modules
54  PCB_ZONE_AREA_T, // in m_ZoneDescriptorList
55  EOT
56 };
57 
58 
61  PCB_TEXT_T,
62  PCB_LINE_T,
65  PCB_VIA_T,
69  EOT
70 };
71 
72 
75  PCB_TEXT_T,
76  PCB_LINE_T,
79  PCB_VIA_T,
81  PCB_PAD_T,
84  PCB_ZONE_AREA_T, // if it is visible on screen, it should be selectable
85  EOT
86 };
87 
88 
91  EOT
92 };
93 
94 
96  PCB_PAD_T,
98  EOT
99 };
100 
101 
103  PCB_PAD_T,
104  PCB_VIA_T,
105  PCB_TRACE_T,
106  EOT
107 };
108 
109 
113  PCB_PAD_T,
114  PCB_MODULE_T,
115  EOT
116 };
117 
118 
122  PCB_PAD_T,
123  EOT
124 };
125 
126 
128  PCB_TRACE_T,
129  PCB_VIA_T,
130  EOT
131 };
132 
133 
135  PCB_MODULE_T,
136  PCB_TRACE_T,
137  PCB_VIA_T,
138  EOT
139 };
140 
141 
144  EOT
145 };
146 
147 
148 
150 {
151  BOARD_ITEM* item = (BOARD_ITEM*) testItem;
152  MODULE* module = NULL;
153  D_PAD* pad = NULL;
154  bool pad_through = false;
155  VIA* via = NULL;
156  MARKER_PCB* marker = NULL;
157  ZONE_CONTAINER* zone = NULL;
158 
159 #if 0 // debugging
160  static int breakhere = 0;
161 
162  switch( item->Type() )
163  {
164  case PCB_PAD_T:
165  {
166  MODULE* m = (MODULE*) item->GetParent();
167 
168  if( m->GetReference() == wxT( "Y2" ) )
169  {
170  breakhere++;
171  }
172  }
173  break;
174 
175  case PCB_VIA_T:
176  breakhere++;
177  break;
178 
179  case PCB_TRACE_T:
180  breakhere++;
181  break;
182 
183  case PCB_TEXT_T:
184  breakhere++;
185  break;
186 
187  case PCB_LINE_T:
188  breakhere++;
189  break;
190 
191  case PCB_DIMENSION_T:
192  breakhere++;
193  break;
194 
195  case PCB_MODULE_TEXT_T:
196  {
197  TEXTE_MODULE* tm = (TEXTE_MODULE*) item;
198 
199  if( tm->GetText() == wxT( "10uH" ) )
200  {
201  breakhere++;
202  }
203  }
204  break;
205 
206  case PCB_MODULE_T:
207  {
208  MODULE* m = (MODULE*) item;
209 
210  if( m->GetReference() == wxT( "C98" ) )
211  {
212  breakhere++;
213  }
214  }
215  break;
216 
217  case PCB_MARKER_T:
218  breakhere++;
219  break;
220 
221  default:
222  breakhere++;
223  break;
224  }
225 
226 #endif
227 
228 
229  switch( item->Type() )
230  {
231  case PCB_PAD_T:
232  // there are pad specific visibility controls.
233  // Criterias to select a pad is:
234  // for smd pads: the module parent must be seen, and pads on the corresponding
235  // board side must be seen
236  // if pad is a thru hole, then it can be visible when its parent module is not.
237  // for through pads: pads on Front or Back board sides must be seen
238  pad = (D_PAD*) item;
239 
240  if( (pad->GetAttribute() != PAD_ATTRIB_SMD) &&
241  (pad->GetAttribute() != PAD_ATTRIB_CONN) ) // a hole is present, so multiple layers
242  {
243  // proceed to the common tests below, but without the parent module test,
244  // by leaving module==NULL, but having pad != null
245  pad_through = true;
246  }
247  else // smd, so use pads test after module test
248  {
249  module = static_cast<MODULE*>( item->GetParent() );
250  }
251 
252  break;
253 
254  case PCB_VIA_T: // vias are on many layers, so layer test is specific
255  via = static_cast<VIA*>( item );
256  break;
257 
258  case PCB_TRACE_T:
259  if( m_Guide->IgnoreTracks() )
260  goto exit;
261  break;
262 
263  case PCB_ZONE_AREA_T:
264  zone = static_cast<ZONE_CONTAINER*>( item );
265  break;
266 
267  case PCB_TEXT_T:
268  break;
269 
270  case PCB_LINE_T:
271  break;
272 
273  case PCB_DIMENSION_T:
274  break;
275 
276  case PCB_TARGET_T:
277  break;
278 
279  case PCB_MODULE_TEXT_T:
280  {
281  TEXTE_MODULE *text = static_cast<TEXTE_MODULE*>( item );
282  if( m_Guide->IgnoreMTextsMarkedNoShow() && !text->IsVisible() )
283  goto exit;
284 
285  if( m_Guide->IgnoreMTextsOnBack() && IsBackLayer( text->GetLayer() ) )
286  goto exit;
287 
288  if( m_Guide->IgnoreMTextsOnFront() && IsFrontLayer( text->GetLayer() ) )
289  goto exit;
290 
291  /* The three text types have different criteria: reference
292  * and value have their own ignore flags; user text instead
293  * follows their layer visibility. Checking this here is
294  * simpler than later (when layer visibility is checked for
295  * other entities) */
296 
297  switch( text->GetType() )
298  {
300  if( m_Guide->IgnoreModulesRefs() )
301  goto exit;
302  break;
303 
305  if( m_Guide->IgnoreModulesVals() )
306  goto exit;
307  break;
308 
310  if( !m_Guide->IsLayerVisible( text->GetLayer() )
312  goto exit;
313  break;
314  }
315 
316  // Extract the module since it could be hidden
317  module = static_cast<MODULE*>( item->GetParent() );
318  }
319  break;
320 
321  case PCB_MODULE_T:
322  module = static_cast<MODULE*>( item );
323  break;
324 
325  case PCB_MARKER_T:
326  marker = static_cast<MARKER_PCB*>( item );
327  break;
328 
329  default:
330  break;
331  }
332 
333  // common tests:
334 
335  if( module ) // true from case PCB_PAD_T, PCB_MODULE_TEXT_T, or PCB_MODULE_T
336  {
337  if( m_Guide->IgnoreModulesOnBack() && (module->GetLayer() == B_Cu) )
338  goto exit;
339 
340  if( m_Guide->IgnoreModulesOnFront() && (module->GetLayer() == F_Cu) )
341  goto exit;
342  }
343 
344  // Pads are not sensitive to the layer visibility controls.
345  // They all have their own separate visibility controls
346  // skip them if not visible
347  if( pad )
348  {
349  if( m_Guide->IgnorePads() )
350  goto exit;
351 
352  if( ! pad_through )
353  {
354  if( m_Guide->IgnorePadsOnFront() && pad->IsOnLayer(F_Cu ) )
355  goto exit;
356 
357  if( m_Guide->IgnorePadsOnBack() && pad->IsOnLayer(B_Cu ) )
358  goto exit;
359  }
360  }
361 
362  if( marker )
363  {
364  // Markers are not sensitive to the layer
365  if( marker->HitTest( m_RefPos ) )
366  Append( item );
367 
368  goto exit;
369  }
370 
371  if( via )
372  {
373  auto type = via->GetViaType();
374 
375  if( ( m_Guide->IgnoreThroughVias() && type == VIA_THROUGH ) ||
376  ( m_Guide->IgnoreBlindBuriedVias() && type == VIA_BLIND_BURIED ) ||
377  ( m_Guide->IgnoreMicroVias() && type == VIA_MICROVIA ) )
378  {
379  goto exit;
380  }
381  }
382 
384  {
385  PCB_LAYER_ID layer = item->GetLayer();
386 
387  // Modules and their subcomponents: reference, value and pads are not sensitive
388  // to the layer visibility controls. They all have their own separate visibility
389  // controls for vias, GetLayer() has no meaning, but IsOnLayer() works fine. User
390  // text in module *is* sensitive to layer visibility but that was already handled.
391 
392  if( via || module || pad || m_Guide->IsLayerVisible( layer )
394  {
395  if( !m_Guide->IsLayerLocked( layer ) || !m_Guide->IgnoreLockedLayers() )
396  {
397  if( !item->IsLocked() || !m_Guide->IgnoreLockedItems() )
398  {
399  if( zone )
400  {
401  bool testFill = !m_Guide->IgnoreZoneFills();
402  int accuracy = KiROUND( 5 * m_Guide->OnePixelInIU() );
403 
404  if( zone->HitTestForCorner( m_RefPos, accuracy * 2 )
405  || zone->HitTestForEdge( m_RefPos, accuracy )
406  || ( testFill && zone->HitTestFilledArea( m_RefPos ) ) )
407  {
408  Append( item );
409  goto exit;
410  }
411  }
412  else if( item->HitTest( m_RefPos ) )
413  {
414  if( !module || module->HitTestAccurate( m_RefPos ) )
415  Append( item );
416 
417  goto exit;
418  }
419  }
420  }
421  }
422  }
423 
424 
425  if( m_Guide->IncludeSecondary() )
426  {
427  // for now, "secondary" means "tolerate any layer". It has
428  // no effect on other criteria, since there is a separate "ignore" control for
429  // those in the COLLECTORS_GUIDE
430 
431  PCB_LAYER_ID layer = item->GetLayer();
432 
433  // Modules and their subcomponents: reference, value and pads are not sensitive
434  // to the layer visibility controls. They all have their own separate visibility
435  // controls for vias, GetLayer() has no meaning, but IsOnLayer() works fine. User
436  // text in module *is* sensitive to layer visibility but that was already handled.
437 
438  if( via || module || pad || m_Guide->IsLayerVisible( layer )
440  {
441  if( !m_Guide->IsLayerLocked( layer ) || !m_Guide->IgnoreLockedLayers() )
442  {
443  if( !item->IsLocked() || !m_Guide->IgnoreLockedItems() )
444  {
445  if( zone )
446  {
447  bool testFill = !m_Guide->IgnoreZoneFills();
448  int accuracy = KiROUND( 5 * m_Guide->OnePixelInIU() );
449 
450  if( zone->HitTestForCorner( m_RefPos, accuracy * 2 )
451  || zone->HitTestForEdge( m_RefPos, accuracy )
452  || ( testFill && zone->HitTestFilledArea( m_RefPos ) ) )
453  {
454  Append2nd( item );
455  goto exit;
456  }
457  }
458  else if( item->HitTest( m_RefPos ) )
459  {
460  Append2nd( item );
461  goto exit;
462  }
463  }
464  }
465  }
466  }
467 
468 exit:
469  return SEARCH_CONTINUE; // always when collecting
470 }
471 
472 
473 void GENERAL_COLLECTOR::Collect( BOARD_ITEM* aItem, const KICAD_T aScanList[],
474  const wxPoint& aRefPos, const COLLECTORS_GUIDE& aGuide )
475 {
476  Empty(); // empty the collection, primary criteria list
477  Empty2nd(); // empty the collection, secondary criteria list
478 
479  // remember guide, pass it to Inspect()
480  SetGuide( &aGuide );
481 
482  SetScanTypes( aScanList );
483 
484  // remember where the snapshot was taken from and pass refPos to
485  // the Inspect() function.
486  SetRefPos( aRefPos );
487 
488  aItem->Visit( m_inspector, NULL, m_ScanTypes );
489 
490  SetTimeNow(); // when snapshot was taken
491 
492  // record the length of the primary list before concatenating on to it.
493  m_PrimaryLength = m_List.size();
494 
495  // append 2nd list onto end of the first list
496  for( unsigned i = 0; i<m_List2nd.size(); ++i )
497  Append( m_List2nd[i] );
498 
499  Empty2nd();
500 }
501 
502 
504 {
505  // The Visit() function only visits the testItem if its type was in the
506  // the scanList, so therefore we can collect anything given to us here.
507  Append( testItem );
508 
509  return SEARCH_CONTINUE; // always when collecting
510 }
511 
512 
513 void PCB_TYPE_COLLECTOR::Collect( BOARD_ITEM* aBoard, const KICAD_T aScanList[] )
514 {
515  Empty(); // empty any existing collection
516 
517  aBoard->Visit( m_inspector, NULL, aScanList );
518 }
519 
520 
522 {
523  BOARD_ITEM* item = (BOARD_ITEM*) testItem;
524 
525  if( item->Type() == PCB_PAD_T ) // multilayer
526  {
527  if( static_cast<D_PAD*>( item )->IsOnLayer( m_layer_id ) )
528  Append( testItem );
529  }
530  else if( item->GetLayer() == m_layer_id )
531  Append( testItem );
532 
533  return SEARCH_CONTINUE;
534 }
535 
536 
537 void PCB_LAYER_COLLECTOR::Collect( BOARD_ITEM* aBoard, const KICAD_T aScanList[] )
538 {
539  Empty();
540 
541  aBoard->Visit( m_inspector, NULL, aScanList );
542 }
void Empty()
Function Empty sets the list to empty.
Definition: collector.h:123
virtual bool IsLayerLocked(PCB_LAYER_ID layer) const =0
Class ZONE_CONTAINER handles a list of polygons defining a copper zone.
Definition: class_zone.h:59
virtual SEARCH_RESULT Visit(INSPECTOR inspector, void *testData, const KICAD_T scanTypes[])
Function Visit may be re-implemented for each derived class in order to handle all the types given by...
static const KICAD_T BoardLevelItems[]
A scan list for all primary board items, omitting items which are subordinate to a MODULE,...
Definition: collectors.h:283
virtual bool IgnoreBlindBuriedVias() const =0
virtual bool IgnoreModulesOnFront() const =0
static const KICAD_T AllBoardItems[]
A scan list for all editable board items, like PcbGeneralLocateAndDisplay()
Definition: collectors.h:267
static const KICAD_T Tracks[]
A scan list for only TRACKS.
Definition: collectors.h:313
static int KiROUND(double v)
Round a floating point number to an integer using "round halfway cases away from zero".
Definition: common.h:118
SEARCH_RESULT Inspect(EDA_ITEM *testItem, void *testData) override
The examining function within the INSPECTOR which is passed to the iterate function.
Definition: collectors.cpp:521
Class BOARD_ITEM is a base class for any item which can be embedded within the BOARD container class,...
static const KICAD_T Modules[]
A scan list for only MODULEs.
Definition: collectors.h:288
void SetScanTypes(const KICAD_T *scanTypes)
Function SetScanTypes records the list of KICAD_T types to consider for collection by the Inspect() f...
Definition: collector.h:215
void Collect(BOARD_ITEM *aItem, const KICAD_T aScanList[], const wxPoint &aRefPos, const COLLECTORS_GUIDE &aGuide)
Scan a BOARD_ITEM using this class's Inspector method, which does the collection.
Definition: collectors.cpp:473
Classes BOARD_ITEM and BOARD_CONNECTED_ITEM.
virtual double OnePixelInIU() const =0
bool IsBackLayer(PCB_LAYER_ID aLayerId)
Layer classification: check if it's a back layer.
bool IsVisible() const
Definition: eda_text.h:193
bool HitTestForCorner(const wxPoint &refPos, int aAccuracy, SHAPE_POLY_SET::VERTEX_INDEX &aCornerHit) const
Function HitTestForCorner tests if the given wxPoint is near a corner.
Definition: class_zone.cpp:678
virtual bool IgnoreZoneFills() const =0
virtual bool IgnoreNonVisibleLayers() const =0
Smd pad, appears on the solder paste layer (default)
Definition: pad_shapes.h:62
class ZONE_CONTAINER, a zone area
Definition: typeinfo.h:100
void Append2nd(BOARD_ITEM *item)
Definition: collectors.h:335
class TEXTE_PCB, text on a layer
Definition: typeinfo.h:92
virtual PCB_LAYER_ID GetPreferredLayer() const =0
bool HitTestFilledArea(const wxPoint &aRefPos) const
Function HitTestFilledArea tests if the given wxPoint is within the bounds of a filled area of this z...
Definition: class_zone.cpp:802
void Collect(BOARD_ITEM *aBoard, const KICAD_T aScanList[])
Tests a BOARD_ITEM using this class's Inspector method, which does the collection.
Definition: collectors.cpp:537
PCB_LAYER_ID m_layer_id
Definition: collectors.h:653
static const KICAD_T AllButZones[]
A scan list for all editable board items, except zones.
Definition: collectors.h:272
Classes to handle copper zones.
virtual bool IgnoreTracks() const =0
std::vector< BOARD_ITEM * > m_List2nd
A place to hold collected objects which don't match precisely the search criteria,...
Definition: collectors.h:249
virtual const wxString GetText() const
Function GetText returns the string associated with the text object.
Definition: eda_text.h:147
class D_PAD, a pad in a footprint
Definition: typeinfo.h:90
virtual bool IgnoreMicroVias() const =0
virtual bool IgnoreModulesVals() const =0
static const KICAD_T PadsOrTracks[]
A scan list for PADs, TRACKs, or VIAs.
Definition: collectors.h:298
int m_PrimaryLength
The number of items that were originally in the primary list before the m_List2nd was concatenated on...
Definition: collectors.h:260
virtual bool IgnorePreferredLayer() const =0
Provide wildcard behavior regarding the preferred layer.
class EDGE_MODULE, a footprint edge
Definition: typeinfo.h:94
search types array terminator (End Of Types)
Definition: typeinfo.h:82
KICAD_T
Enum KICAD_T is the set of class identification values, stored in EDA_ITEM::m_StructType.
Definition: typeinfo.h:78
PAD_ATTR_T GetAttribute() const
Definition: class_pad.h:417
Functions relatives to tracks, vias and segments used to fill zones.
class TRACK, a track segment (segment on a copper layer)
Definition: typeinfo.h:95
const wxString GetReference() const
Function GetReference.
Definition: class_module.h:462
static const KICAD_T ModulesAndTheirItems[]
A scan list for MODULEs and their items (for Modedit)
Definition: collectors.h:303
virtual bool IgnorePadsOnFront() const =0
void Append(EDA_ITEM *item)
Function Append adds an item to the end of the list.
Definition: collector.h:133
void SetGuide(const COLLECTORS_GUIDE *aGuide)
Record which COLLECTORS_GUIDE to use.
Definition: collectors.h:345
virtual bool HitTest(const wxPoint &aPosition, int aAccuracy=0) const
Function HitTest tests if aPosition is contained within or on the bounding box of an item.
Definition: base_struct.h:333
class MODULE, a footprint
Definition: typeinfo.h:89
SEARCH_RESULT Inspect(EDA_ITEM *testItem, void *testData) override
The examining function within the INSPECTOR which is passed to the Iterate function.
Definition: collectors.cpp:503
Markers used to show a drc problem on boards.
INSPECTOR_FUNC m_inspector
a class common bridge into the polymorphic Inspect()
Definition: collector.h:59
PCB_LAYER_ID
A quick note on layer IDs:
virtual bool IsOnLayer(PCB_LAYER_ID aLayer) const
Function IsOnLayer tests to see if this object is on the given layer.
virtual bool IgnoreMTextsOnBack() const =0
void SetRefPos(const wxPoint &aRefPos)
Definition: collector.h:230
TEXT_TYPE GetType() const
static const KICAD_T Zones[]
A scan list for zones outlines only.
Definition: collectors.h:277
VIATYPE_T GetViaType() const
Definition: class_track.h:437
const COLLECTORS_GUIDE * m_Guide
Determines which items are to be collected by Inspect()
Definition: collectors.h:254
virtual bool IgnoreMTextsMarkedNoShow() const =0
Like smd, does not appear on the solder paste layer (default) note also has a special attribute in Ge...
Definition: pad_shapes.h:63
class DIMENSION, a dimension (graphic item)
Definition: typeinfo.h:98
void Collect(BOARD_ITEM *aBoard, const KICAD_T aScanList[])
Collect BOARD_ITEM objects using this class's Inspector method, which does the collection.
Definition: collectors.cpp:513
virtual bool IgnoreThroughVias() const =0
Pad object description.
class PCB_TARGET, a target (graphic item)
Definition: typeinfo.h:99
virtual bool IgnoreModulesRefs() const =0
class TEXTE_MODULE, text in a footprint
Definition: typeinfo.h:93
bool IsFrontLayer(PCB_LAYER_ID aLayerId)
Layer classification: check if it's a front layer.
static const KICAD_T LockableItems[]
A scan list for TRACKS, VIAS, MODULES.
Definition: collectors.h:318
bool HitTestAccurate(const wxPoint &aPosition, int aAccuracy=0) const
Tests if a point is inside the bounding polygon of the module.
virtual bool IsLocked() const
Function IsLocked.
bool HitTest(const wxPoint &aPosition, int aAccuracy=0) const override
Function HitTest tests if aPosition is contained within or on the bounding box of an item.
class MARKER_PCB, a marker used to show something
Definition: typeinfo.h:97
void SetTimeNow()
Definition: collector.h:220
static const KICAD_T PadsOrModules[]
A scan list for PADs or MODULEs.
Definition: collectors.h:293
virtual bool IgnorePads() const
Definition: collectors.h:152
static const KICAD_T ModuleItems[]
A scan list for primary module items.
Definition: collectors.h:308
size_t i
Definition: json11.cpp:597
Class EDA_ITEM is a base class for most all the KiCad significant classes, used in schematics and boa...
Definition: base_struct.h:157
virtual bool IsLayerVisible(PCB_LAYER_ID layer) const =0
bool HitTestForEdge(const wxPoint &refPos, int aAccuracy, SHAPE_POLY_SET::VERTEX_INDEX &aCornerHit) const
Function HitTestForEdge tests if the given wxPoint is near a segment defined by 2 corners.
Definition: class_zone.cpp:692
class VIA, a via (like a track segment on a copper layer)
Definition: typeinfo.h:96
virtual bool IgnorePadsOnBack() const =0
wxPoint m_RefPos
A point to test against, and that was used to make the collection.
Definition: collector.h:68
Module description (excepted pads)
An abstract base class whose derivatives may be passed to a GENERAL_COLLECTOR, telling GENERAL_COLLEC...
Definition: collectors.h:59
virtual bool IgnoreLockedItems() const =0
virtual bool IgnoreLockedLayers() const =0
SEARCH_RESULT
Definition: base_struct.h:66
std::vector< EDA_ITEM * > m_List
A place to hold collected objects without taking ownership of their memory.
Definition: collector.h:65
bool IsOnLayer(PCB_LAYER_ID aLayer) const override
Function IsOnLayer tests to see if this object is on the given layer.
Definition: class_pad.h:717
virtual bool IgnoreModulesOnBack() const =0
virtual bool IgnoreMTextsOnFront() const =0
class DRAWSEGMENT, a segment not on copper layers
Definition: typeinfo.h:91
virtual bool IncludeSecondary() const =0
Determine if the secondary criteria or 2nd choice items should be included.
BOARD_ITEM_CONTAINER * GetParent() const
const KICAD_T * m_ScanTypes
Which object types to scan.
Definition: collector.h:62
virtual PCB_LAYER_ID GetLayer() const
Function GetLayer returns the primary layer this item is on.
SEARCH_RESULT Inspect(EDA_ITEM *testItem, void *testData) override
The examining function within the INSPECTOR which is passed to the Iterate function.
Definition: collectors.cpp:149
KICAD_T Type() const
Function Type()
Definition: base_struct.h:204