90 bool IsPCB_IO()
const override {
return true; }
102 virtual std::vector<std::pair<wxString, wxString>>
107 virtual bool CanReadBoard(
const wxString& aFileName )
const;
120 wxString aAction )> aCallback )
144 std::unique_ptr<BOARD>
LoadBoard(
const wxString& aFileName,
145 const std::map<std::string, UTF8>* aProperties =
nullptr,
159 const std::map<std::string, UTF8>* aProperties =
nullptr,
PROJECT* aProject =
nullptr );
197 const std::map<std::string, UTF8>* aProperties =
nullptr );
213 virtual void FootprintEnumerate( wxArrayString& aFootprintNames,
const wxString& aLibraryPath,
215 const std::map<std::string, UTF8>* aProperties =
nullptr );
242 virtual std::unique_ptr<FOOTPRINT>
ImportFootprint(
const wxString& aFootprintPath, wxString& aFootprintNameOut,
243 const std::map<std::string, UTF8>* aProperties =
nullptr );
266 virtual std::unique_ptr<FOOTPRINT>
FootprintLoad(
const wxString& aLibraryPath,
const wxString& aFootprintName,
267 bool aKeepUUID =
false,
268 const std::map<std::string, UTF8>* aProperties =
nullptr );
278 const std::map<std::string, UTF8>* aProperties =
nullptr );
291 virtual bool FootprintExists(
const wxString& aLibraryPath,
const wxString& aFootprintName,
292 const std::map<std::string, UTF8>* aProperties =
nullptr );
311 const std::map<std::string, UTF8>* aProperties =
nullptr );
327 virtual void FootprintDelete(
const wxString& aLibraryPath,
const wxString& aFootprintName,
328 const std::map<std::string, UTF8>* aProperties =
nullptr );
366 virtual void GetLibraryOptions( std::map<std::string, UTF8>* aListToAppendTo )
const override;
389 virtual void loadBoard(
const wxString& aFileName,
BOARD& aBoard,
bool aIsNewLoad,
390 const std::map<std::string, UTF8>* aProperties,
PROJECT* aProject );
Information pertinent to a Pcbnew printed circuit board.
BOARD * m_board
The board BOARD being worked on, no ownership here.
virtual bool CanReadFootprint(const wxString &aFileName) const
Check if this PCB_IO can read a footprint from specified file or directory.
virtual bool CachesEnumeratedFootprints() const
Return true if GetEnumeratedFootprint() returns a borrowed pointer from an internal cache.
virtual std::unique_ptr< FOOTPRINT > FootprintLoad(const wxString &aLibraryPath, const wxString &aFootprintName, bool aKeepUUID=false, const std::map< std::string, UTF8 > *aProperties=nullptr)
Load a footprint having aFootprintName from the aLibraryPath containing a library format that this PC...
void LoadAndAppendBoard(const wxString &aFileName, BOARD &aAppendToMe, const std::map< std::string, UTF8 > *aProperties=nullptr, PROJECT *aProject=nullptr)
Same as LoadBoard(), but appends the loaded board to an existing board, which must already exist.
virtual long long GetLibraryTimestamp(const wxString &aLibraryPath) const =0
Generate a timestamp representing all the files in the library (including the library directory).
virtual void SetQueryUserCallback(std::function< bool(wxString aTitle, int aIcon, wxString aMessage, wxString aAction)> aCallback)
Register a KIDIALOG callback for collecting info from the user.
virtual bool CanReadBoard(const wxString &aFileName) const
virtual void SaveBoard(const wxString &aFileName, BOARD &aBoard, const std::map< std::string, UTF8 > *aProperties=nullptr)
Write aBoard to a storage file in a format that this PCB_IO implementation knows about or it can be u...
virtual std::vector< std::pair< wxString, wxString > > EnumerateProjectBoards(const wxString &aFileName) const
Check if this PCB_IO can read the specified board file.
virtual void ClearCachedFootprints(const wxString &aLibraryPath)
Clear any cached footprint data for the given library path.
PCB_IO(const wxString &aName)
virtual void FootprintEnumerate(wxArrayString &aFootprintNames, const wxString &aLibraryPath, bool aBestEfforts, const std::map< std::string, UTF8 > *aProperties=nullptr)
Return a list of footprint names contained within the library at aLibraryPath.
virtual std::unique_ptr< FOOTPRINT > ImportFootprint(const wxString &aFootprintPath, wxString &aFootprintNameOut, const std::map< std::string, UTF8 > *aProperties=nullptr)
Load a single footprint from aFootprintPath and put its name in aFootprintNameOut.
bool IsPCB_IO() const override
Work-around for lack of dynamic_cast across compile units on Mac.
virtual void GetLibraryOptions(std::map< std::string, UTF8 > *aListToAppendTo) const override
Append supported PLUGIN options to aListToAppenTo along with internationalized descriptions.
std::unique_ptr< BOARD > LoadBoard(const wxString &aFileName, const std::map< std::string, UTF8 > *aProperties=nullptr, PROJECT *aProject=nullptr)
Load information from some input file format that this PCB_IO implementation knows about into new BOA...
const std::map< std::string, UTF8 > * m_props
Properties passed via Save() or Load(), no ownership, may be NULL.
virtual bool FootprintExists(const wxString &aLibraryPath, const wxString &aFootprintName, const std::map< std::string, UTF8 > *aProperties=nullptr)
Check for the existence of a footprint.
virtual std::vector< FOOTPRINT * > GetImportedCachedLibraryFootprints()
Return a container with the cached library footprints generated in the last call to Load.
virtual void loadBoard(const wxString &aFileName, BOARD &aBoard, bool aIsNewLoad, const std::map< std::string, UTF8 > *aProperties, PROJECT *aProject)
Parse aFileName into aBoard.
virtual const FOOTPRINT * GetEnumeratedFootprint(const wxString &aLibraryPath, const wxString &aFootprintName, const std::map< std::string, UTF8 > *aProperties=nullptr)
A version of FootprintLoad() for use after FootprintEnumerate() for more efficient cache management i...
virtual wxString GetImportedDesignRules() const
Return custom DRC rules generated while importing the most recent board.
virtual const IO_BASE::IO_FILE_DESC GetBoardFileDesc() const
Return board file description for the PCB_IO.
virtual void FootprintDelete(const wxString &aLibraryPath, const wxString &aFootprintName, const std::map< std::string, UTF8 > *aProperties=nullptr)
Delete aFootprintName from the library at aLibraryPath.
virtual void FootprintSave(const wxString &aLibraryPath, const FOOTPRINT *aFootprint, const std::map< std::string, UTF8 > *aProperties=nullptr)
Write aFootprint to an existing library located at aLibraryPath.
A progress reporter interface for use in multi-threaded environments.
Container for project specific data.
Some functions to handle hotkeys in KiCad.
constexpr char APPEND_PRESERVE_DESTINATION_STACKUP[]
Container that describes file type info.