22#ifndef NETLIST_EXPORTER_H
23#define NETLIST_EXPORTER_H
51 bool Lookup(
const wxString& aString )
53 std::pair<us_iterator, bool> pair =
m_set.insert( aString );
75 PIN_INFO(
const wxString& aPinNumber,
const wxString& aNetName,
const wxString& aPinName,
76 const wxString& aSourcePin = wxEmptyString ) :
99 wxASSERT( aSchematic );
109 virtual bool WriteNetlist(
const wxString& aOutFileName,
unsigned aNetlistOptions,
144 static wxString
MakeCommandLine(
const wxString& aFormatString,
const wxString& aNetlistFile,
145 const wxString& aFinalFile,
146 const wxString& aProjectDirectory );
159 bool aKeepUnconnectedPins );
186 const wxString& aNetName );
191 const std::set<wxString>&
footprintPads(
const wxString& aFootprintId )
const;
202 std::vector<PIN_INFO>& aPins,
bool aKeepUnconnectedPins );
A base class for most all the KiCad significant classes used in schematics and boards.
A minimalistic software bus for communications between various DLLs/DSOs (DSOs) within the same KiCad...
Define a library symbol object.
SCHEMATIC * m_schematic
The schematic we're generating a netlist for.
virtual bool WriteNetlist(const wxString &aOutFileName, unsigned aNetlistOptions, REPORTER &aReporter)
Write to specified output file.
std::vector< PIN_INFO > CreatePinList(SCH_SYMBOL *aSymbol, const SCH_SHEET_PATH &aSheetPath, bool aKeepUnconnectedPins)
Find a symbol from the DrawList and builds its pin list.
virtual ~NETLIST_EXPORTER_BASE()=default
const std::set< wxString > & footprintPads(const wxString &aFootprintId) const
void findAllUnitsOfSymbol(SCH_SYMBOL *aSchSymbol, const SCH_SHEET_PATH &aSheetPath, std::vector< PIN_INFO > &aPins, bool aKeepUnconnectedPins)
Find all units for symbols with multiple symbols per package.
SCH_SYMBOL * findNextSymbol(EDA_ITEM *aItem, const SCH_SHEET_PATH &aSheetPath)
Check if the given symbol should be processed for netlisting.
std::map< wxString, std::set< wxString > > m_footprintPadCache
std::set< LIB_SYMBOL *, LIB_SYMBOL_LESS_THAN > m_libParts
unique library symbols used. LIB_SYMBOL items are sorted by names
void eraseDuplicatePins(std::vector< PIN_INFO > &pins)
Erase duplicate pins.
std::vector< wxString > resolvePadNumbers(const SCH_PIN *aPin, const SCH_SHEET_PATH &aSheetPath) const
Resolve aPin to its effective pad number(s) for every netlist path (issue #2282).
NETLIST_EXPORTER_BASE(SCHEMATIC *aSchematic)
UNIQUE_STRINGS m_referencesAlreadyFound
Used for "multiple symbols per package" symbols to avoid processing a lib symbol more than once.
void SetKiway(KIWAY *aKiway)
static wxString MakeCommandLine(const wxString &aFormatString, const wxString &aNetlistFile, const wxString &aFinalFile, const wxString &aProjectDirectory)
Build up a string that describes a command line for executing a child process.
void appendResolvedPins(std::vector< PIN_INFO > &aPins, const SCH_PIN *aPin, const SCH_SHEET_PATH &aSheetPath, const wxString &aNetName)
Resolve aPin to its pad number(s) and append a PIN_INFO for each (issue #2282).
A pure virtual class used to derive REPORTER objects from.
Holds all the data relating to one schematic.
Handle access to a stack of flattened SCH_SHEET objects by way of a path for creating a flattened sch...
Track unique wxStrings and is useful in telling if a string has been seen before.
std::set< wxString > m_set
set of wxStrings already found
void Clear()
Erase the record.
bool Lookup(const wxString &aString)
std::set< wxString >::iterator us_iterator
Used by std:set<LIB_SYMBOL*> instantiation which uses LIB_SYMBOL name as its key.
bool operator()(LIB_SYMBOL *const &libsymbol1, LIB_SYMBOL *const &libsymbol2) const
PIN_INFO(const wxString &aPinNumber, const wxString &aNetName, const wxString &aPinName, const wxString &aSourcePin=wxEmptyString)
wxString num
Resolved footprint pad number.
wxString srcPin
Original symbol pin number that mapped to this pad (issue #2282).