KiCad PCB EDA Suite
|
#include <altium_parser.h>
Public Member Functions | |
ALTIUM_COMPOUND_FILE (const wxString &aFilePath) | |
Open a CFB file. More... | |
ALTIUM_COMPOUND_FILE (const void *aBuffer, size_t aLen) | |
Load a CFB file from memory. More... | |
ALTIUM_COMPOUND_FILE (const ALTIUM_COMPOUND_FILE &temp_obj)=delete | |
ALTIUM_COMPOUND_FILE & | operator= (const ALTIUM_COMPOUND_FILE &temp_obj)=delete |
~ALTIUM_COMPOUND_FILE ()=default | |
const CFB::CompoundFileReader & | GetCompoundFileReader () const |
std::unique_ptr< ALTIUM_COMPOUND_FILE > | DecodeIntLibStream (const CFB::COMPOUND_FILE_ENTRY &cfe) |
std::map< wxString, wxString > | ListLibFootprints () |
std::tuple< wxString, const CFB::COMPOUND_FILE_ENTRY * > | FindLibFootprintDirName (const wxString &aFpUnicodeName) |
const CFB::COMPOUND_FILE_ENTRY * | FindStream (const std::vector< std::string > &aStreamPath) const |
const CFB::COMPOUND_FILE_ENTRY * | FindStream (const CFB::COMPOUND_FILE_ENTRY *aStart, const std::vector< std::string > &aStreamPath) const |
const CFB::COMPOUND_FILE_ENTRY * | FindStreamSingleLevel (const CFB::COMPOUND_FILE_ENTRY *aEntry, const std::string aName, const bool aIsStream) const |
std::map< wxString, const CFB::COMPOUND_FILE_ENTRY * > | EnumDir (const std::wstring &aDir) const |
std::map< wxString, const CFB::COMPOUND_FILE_ENTRY * > | GetLibSymbols (const CFB::COMPOUND_FILE_ENTRY *aStart) const |
Private Member Functions | |
void | cacheLibFootprintNames () |
Private Attributes | |
std::unique_ptr< CFB::CompoundFileReader > | m_reader |
std::vector< char > | m_buffer |
std::map< wxString, const CFB::COMPOUND_FILE_ENTRY * > | m_libFootprintNameCache |
std::map< wxString, wxString > | m_libFootprintDirNameCache |
Definition at line 54 of file altium_parser.h.
ALTIUM_COMPOUND_FILE::ALTIUM_COMPOUND_FILE | ( | const wxString & | aFilePath | ) |
Open a CFB file.
Constructor might throw an IO_ERROR.
aFilePath | path to file to open |
Definition at line 49 of file altium_parser.cpp.
References _, m_buffer, m_reader, and THROW_IO_ERROR.
ALTIUM_COMPOUND_FILE::ALTIUM_COMPOUND_FILE | ( | const void * | aBuffer, |
size_t | aLen | ||
) |
Load a CFB file from memory.
Constructor might throw an IO_ERROR. Data is copied.
aBuffer | data buffer |
aLen | data length |
Definition at line 92 of file altium_parser.cpp.
References m_buffer, m_reader, and THROW_IO_ERROR.
|
delete |
|
default |
|
private |
Definition at line 326 of file altium_parser.cpp.
References m_libFootprintDirNameCache, m_libFootprintNameCache, and m_reader.
Referenced by FindLibFootprintDirName(), and ListLibFootprints().
std::unique_ptr< ALTIUM_COMPOUND_FILE > ALTIUM_COMPOUND_FILE::DecodeIntLibStream | ( | const CFB::COMPOUND_FILE_ENTRY & | cfe | ) |
Definition at line 109 of file altium_parser.cpp.
References GetCompoundFileReader().
std::map< wxString, const CFB::COMPOUND_FILE_ENTRY * > ALTIUM_COMPOUND_FILE::EnumDir | ( | const std::wstring & | aDir | ) | const |
Definition at line 243 of file altium_parser.cpp.
References m_reader.
std::tuple< wxString, const CFB::COMPOUND_FILE_ENTRY * > ALTIUM_COMPOUND_FILE::FindLibFootprintDirName | ( | const wxString & | aFpUnicodeName | ) |
Definition at line 161 of file altium_parser.cpp.
References cacheLibFootprintNames(), and m_libFootprintNameCache.
Referenced by ALTIUM_PCB::ParseFootprint().
const CFB::COMPOUND_FILE_ENTRY * ALTIUM_COMPOUND_FILE::FindStream | ( | const CFB::COMPOUND_FILE_ENTRY * | aStart, |
const std::vector< std::string > & | aStreamPath | ||
) | const |
Definition at line 288 of file altium_parser.cpp.
References FindStreamSingleLevel(), m_reader, and name.
const CFB::COMPOUND_FILE_ENTRY * ALTIUM_COMPOUND_FILE::FindStream | ( | const std::vector< std::string > & | aStreamPath | ) | const |
Definition at line 320 of file altium_parser.cpp.
References FindStream().
Referenced by FindStream(), ALTIUM_PCB::Parse(), SCH_ALTIUM_PLUGIN::ParseAdditional(), SCH_ALTIUM_PLUGIN::ParseFileHeader(), ALTIUM_PCB::ParseFootprint(), SCH_ALTIUM_PLUGIN::ParseLibHeader(), ALTIUM_PCB::ParseModelsData(), and SCH_ALTIUM_PLUGIN::ParseStorage().
const CFB::COMPOUND_FILE_ENTRY * ALTIUM_COMPOUND_FILE::FindStreamSingleLevel | ( | const CFB::COMPOUND_FILE_ENTRY * | aEntry, |
const std::string | aName, | ||
const bool | aIsStream | ||
) | const |
|
inline |
Definition at line 77 of file altium_parser.h.
References m_reader.
Referenced by ALTIUM_PARSER::ALTIUM_PARSER(), DecodeIntLibStream(), and ALTIUM_PCB::ParseModelsData().
std::map< wxString, const CFB::COMPOUND_FILE_ENTRY * > ALTIUM_COMPOUND_FILE::GetLibSymbols | ( | const CFB::COMPOUND_FILE_ENTRY * | aStart | ) | const |
Definition at line 208 of file altium_parser.cpp.
References m_reader.
Referenced by SCH_ALTIUM_PLUGIN::ParseLibFile().
std::map< wxString, wxString > ALTIUM_COMPOUND_FILE::ListLibFootprints | ( | ) |
Definition at line 151 of file altium_parser.cpp.
References cacheLibFootprintNames(), and m_libFootprintDirNameCache.
|
delete |
|
private |
Definition at line 102 of file altium_parser.h.
Referenced by ALTIUM_COMPOUND_FILE().
|
private |
Definition at line 105 of file altium_parser.h.
Referenced by cacheLibFootprintNames(), and ListLibFootprints().
|
private |
Definition at line 104 of file altium_parser.h.
Referenced by cacheLibFootprintNames(), and FindLibFootprintDirName().
|
private |
Definition at line 101 of file altium_parser.h.
Referenced by ALTIUM_COMPOUND_FILE(), cacheLibFootprintNames(), EnumDir(), FindStream(), FindStreamSingleLevel(), GetCompoundFileReader(), and GetLibSymbols().