KiCad PCB EDA Suite
Loading...
Searching...
No Matches
PCAD_SCH_IMPORT_FIXTURE Struct Reference

#include <test_pcad_sch_import_fixture.h>

Public Member Functions

 PCAD_SCH_IMPORT_FIXTURE ()
 
std::string GetTestDataDir ()
 
void LoadSchematic (const std::string &aFile)
 
int CountItemsOfType (KICAD_T aType)
 
int CountImportedScreens ()
 
int CountWires ()
 
int CountBusSegments ()
 
LIB_SYMBOLLibSymbolForRefdes (const wxString &aRefdes)
 The embedded library symbol of the first placed symbol matching the reference.
 
SCH_SYMBOLSymbolForRefdesUnit (const wxString &aRefdes, int aUnit)
 
SCH_PINLibPin (LIB_SYMBOL *aSymbol, const wxString &aNumber)
 The library pin with the given number, searched across all units.
 
bool HasLabel (const wxString &aText, KICAD_T aType=SCH_LABEL_T)
 
SCH_TEXTFindText (const wxString &aText)
 
int CountShapesWithStyle (LINE_STYLE aStyle)
 Count wire or graphic lines drawn with the given stroke style anywhere in the design.
 
template<typename FUNC>
void forEachItemOfType (KICAD_T aType, FUNC aFunc)
 

Public Attributes

SCH_IO_PCAD m_plugin
 
std::unique_ptr< SCHEMATICm_schematic
 
SETTINGS_MANAGER m_manager
 
SCH_SHEETm_loadedRoot = nullptr
 

Detailed Description

Definition at line 51 of file test_pcad_sch_import_fixture.h.

Constructor & Destructor Documentation

◆ PCAD_SCH_IMPORT_FIXTURE()

PCAD_SCH_IMPORT_FIXTURE::PCAD_SCH_IMPORT_FIXTURE ( )
inline

Definition at line 53 of file test_pcad_sch_import_fixture.h.

References m_manager, and m_schematic.

Member Function Documentation

◆ CountBusSegments()

int PCAD_SCH_IMPORT_FIXTURE::CountBusSegments ( )
inline

Definition at line 123 of file test_pcad_sch_import_fixture.h.

References forEachItemOfType(), LAYER_BUS, and SCH_LINE_T.

◆ CountImportedScreens()

int PCAD_SCH_IMPORT_FIXTURE::CountImportedScreens ( )
inline

Definition at line 96 of file test_pcad_sch_import_fixture.h.

References m_schematic.

◆ CountItemsOfType()

int PCAD_SCH_IMPORT_FIXTURE::CountItemsOfType ( KICAD_T aType)
inline

Definition at line 74 of file test_pcad_sch_import_fixture.h.

References SCH_SCREEN::Items(), and m_schematic.

◆ CountShapesWithStyle()

int PCAD_SCH_IMPORT_FIXTURE::CountShapesWithStyle ( LINE_STYLE aStyle)
inline

Count wire or graphic lines drawn with the given stroke style anywhere in the design.

Definition at line 217 of file test_pcad_sch_import_fixture.h.

References forEachItemOfType(), and SCH_SHAPE_T.

◆ CountWires()

int PCAD_SCH_IMPORT_FIXTURE::CountWires ( )
inline

Definition at line 109 of file test_pcad_sch_import_fixture.h.

References forEachItemOfType(), LAYER_WIRE, and SCH_LINE_T.

◆ FindText()

SCH_TEXT * PCAD_SCH_IMPORT_FIXTURE::FindText ( const wxString & aText)
inline

Definition at line 202 of file test_pcad_sch_import_fixture.h.

References forEachItemOfType(), result, and SCH_TEXT_T.

◆ forEachItemOfType()

template<typename FUNC>
void PCAD_SCH_IMPORT_FIXTURE::forEachItemOfType ( KICAD_T aType,
FUNC aFunc )
inline

◆ GetTestDataDir()

std::string PCAD_SCH_IMPORT_FIXTURE::GetTestDataDir ( )
inline

Definition at line 66 of file test_pcad_sch_import_fixture.h.

References KI_TEST::GetEeschemaTestDataDir().

Referenced by LoadSchematic().

◆ HasLabel()

bool PCAD_SCH_IMPORT_FIXTURE::HasLabel ( const wxString & aText,
KICAD_T aType = SCH_LABEL_T )
inline

Definition at line 188 of file test_pcad_sch_import_fixture.h.

References forEachItemOfType(), and SCH_LABEL_T.

◆ LibPin()

SCH_PIN * PCAD_SCH_IMPORT_FIXTURE::LibPin ( LIB_SYMBOL * aSymbol,
const wxString & aNumber )
inline

The library pin with the given number, searched across all units.

Definition at line 174 of file test_pcad_sch_import_fixture.h.

References LIB_SYMBOL::GetPins(), and pin.

◆ LibSymbolForRefdes()

LIB_SYMBOL * PCAD_SCH_IMPORT_FIXTURE::LibSymbolForRefdes ( const wxString & aRefdes)
inline

The embedded library symbol of the first placed symbol matching the reference.

Definition at line 138 of file test_pcad_sch_import_fixture.h.

References forEachItemOfType(), SCH_SYMBOL::GetLibSymbolRef(), SCH_SYMBOL::GetRef(), result, and SCH_SYMBOL_T.

◆ LoadSchematic()

void PCAD_SCH_IMPORT_FIXTURE::LoadSchematic ( const std::string & aFile)
inline

◆ SymbolForRefdesUnit()

SCH_SYMBOL * PCAD_SCH_IMPORT_FIXTURE::SymbolForRefdesUnit ( const wxString & aRefdes,
int aUnit )
inline

Member Data Documentation

◆ m_loadedRoot

SCH_SHEET* PCAD_SCH_IMPORT_FIXTURE::m_loadedRoot = nullptr

Definition at line 64 of file test_pcad_sch_import_fixture.h.

Referenced by LoadSchematic().

◆ m_manager

SETTINGS_MANAGER PCAD_SCH_IMPORT_FIXTURE::m_manager

Definition at line 63 of file test_pcad_sch_import_fixture.h.

Referenced by PCAD_SCH_IMPORT_FIXTURE().

◆ m_plugin

SCH_IO_PCAD PCAD_SCH_IMPORT_FIXTURE::m_plugin

Definition at line 61 of file test_pcad_sch_import_fixture.h.

Referenced by LoadSchematic().

◆ m_schematic

std::unique_ptr<SCHEMATIC> PCAD_SCH_IMPORT_FIXTURE::m_schematic

The documentation for this struct was generated from the following file: