KiCad PCB EDA Suite
Loading...
Searching...
No Matches
import_net_map.h File Reference
#include <kiid.h>
#include <wx/string.h>
#include <cstdint>
#include <iosfwd>
#include <map>
#include <vector>

Go to the source code of this file.

Classes

struct  IMPORT_NET_TERMINAL
 
struct  IMPORT_NET_MAP_ENTRY
 
struct  IMPORT_NET_MAP
 Import provenance, held only for the lifetime of the importing SCHEMATIC. More...
 

Enumerations

enum class  IMPORT_NET_STATUS {
  RESOLVED , SPLIT , BUS , NO_CONNECT ,
  UNCONNECTED
}
 How completely a source net survived conversion. More...
 

Functions

std::ostream & operator<< (std::ostream &aStream, IMPORT_NET_STATUS aStatus)
 Name the status, so test diagnostics read as a status rather than an ordinal.
 
std::map< wxString, wxString > GetBoardNetNameMap (const IMPORT_NET_MAP &aMap, REPORTER &aReporter)
 Reduce the map to the board net renames it justifies.
 

Enumeration Type Documentation

◆ IMPORT_NET_STATUS

enum class IMPORT_NET_STATUS
strong

How completely a source net survived conversion.

Only RESOLVED nets can be renamed on a board.

Enumerator
RESOLVED 

exactly one physical net carries the source net

SPLIT 

the source net reaches more than one physical net

BUS 

the source net is carried by a bus

NO_CONNECT 

the source marks the net as deliberately unconnected

UNCONNECTED 

the source net reaches no physical net

Definition at line 33 of file import_net_map.h.

Function Documentation

◆ GetBoardNetNameMap()

std::map< wxString, wxString > GetBoardNetNameMap ( const IMPORT_NET_MAP & aMap,
REPORTER & aReporter )

Reduce the map to the board net renames it justifies.

Only a source net that one physical net carries can be renamed, and only where the source name was machine-generated, since that is the name the paired board also uses. A generated name that resolved to more than one KiCad name is reported and omitted rather than guessed at.

Definition at line 42 of file import_net_map.cpp.

References _, IMPORT_NET_MAP::entries, IMPORT_NET_MAP_ENTRY::generatedName, IMPORT_NET_MAP_ENTRY::nameAtImport, REPORTER::Report(), RESOLVED, result, RPT_SEVERITY_WARNING, and IMPORT_NET_MAP_ENTRY::status.

Referenced by BOOST_AUTO_TEST_CASE(), EESCHEMA_JOBS_HANDLER::JobImport(), and SCH_EDIT_FRAME::KiwayMailIn().

◆ operator<<()

std::ostream & operator<< ( std::ostream & aStream,
IMPORT_NET_STATUS aStatus )

Name the status, so test diagnostics read as a status rather than an ordinal.

Definition at line 27 of file import_net_map.cpp.

References BUS, NO_CONNECT, RESOLVED, SPLIT, and UNCONNECTED.