KiCad PCB EDA Suite
|
Functions | |
std::optional< KICAD_T > | TypeNameFromAny (const google::protobuf::Any &aMessage) |
LIB_ID | LibIdFromProto (const types::LibraryIdentifier &aId) |
types::LibraryIdentifier | LibIdToProto (const LIB_ID &aId) |
void | PackVector2 (kiapi::common::types::Vector2 &aOutput, const VECTOR2I aInput) |
VECTOR2I | UnpackVector2 (const types::Vector2 &aInput) |
void | PackPolyLine (kiapi::common::types::PolyLine &aOutput, const SHAPE_LINE_CHAIN &aSlc) |
SHAPE_LINE_CHAIN | UnpackPolyLine (const kiapi::common::types::PolyLine &aInput) |
LIB_ID kiapi::common::LibIdFromProto | ( | const types::LibraryIdentifier & | aId | ) |
Definition at line 54 of file api_utils.cpp.
Referenced by FOOTPRINT::Deserialize().
types::LibraryIdentifier kiapi::common::LibIdToProto | ( | const LIB_ID & | aId | ) |
Definition at line 60 of file api_utils.cpp.
References LIB_ID::GetLibItemName(), and LIB_ID::GetLibNickname().
Referenced by FOOTPRINT::Serialize().
void kiapi::common::PackPolyLine | ( | kiapi::common::types::PolyLine & | aOutput, |
const SHAPE_LINE_CHAIN & | aSlc | ||
) |
Definition at line 81 of file api_utils.cpp.
References SHAPE_LINE_CHAIN::Arc(), SHAPE_LINE_CHAIN::ArcIndex(), SHAPE_LINE_CHAIN::CPoint(), SHAPE_ARC::GetArcMid(), SHAPE_ARC::GetP0(), SHAPE_ARC::GetP1(), SHAPE_LINE_CHAIN::IsClosed(), SHAPE_LINE_CHAIN::IsPtOnArc(), SHAPE_LINE_CHAIN::NextShape(), SHAPE_LINE_CHAIN::PointCount(), VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by PCB_SHAPE::Serialize().
void kiapi::common::PackVector2 | ( | kiapi::common::types::Vector2 & | aOutput, |
const VECTOR2I | aInput | ||
) |
Definition at line 69 of file api_utils.cpp.
References VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by SCH_LABEL::Serialize(), SCH_LINE::Serialize(), PAD::Serialize(), PADSTACK::Serialize(), and PCB_SHAPE::Serialize().
std::optional< KICAD_T > kiapi::common::TypeNameFromAny | ( | const google::protobuf::Any & | aMessage | ) |
Definition at line 27 of file api_utils.cpp.
References PCB_ARC_T, PCB_DIMENSION_T, PCB_FIELD_T, PCB_FOOTPRINT_T, PCB_GROUP_T, PCB_PAD_T, PCB_REFERENCE_IMAGE_T, PCB_SHAPE_T, PCB_TEXT_T, PCB_TEXTBOX_T, PCB_TRACE_T, PCB_VIA_T, and PCB_ZONE_T.
Referenced by FOOTPRINT::Deserialize(), API_HANDLER_SCH::handleCreateUpdateItemsInternal(), and API_HANDLER_PCB::handleCreateUpdateItemsInternal().
SHAPE_LINE_CHAIN kiapi::common::UnpackPolyLine | ( | const kiapi::common::types::PolyLine & | aInput | ) |
Definition at line 111 of file api_utils.cpp.
References SHAPE_LINE_CHAIN::Append(), and SHAPE_LINE_CHAIN::SetClosed().
Referenced by PCB_SHAPE::Deserialize().
VECTOR2I kiapi::common::UnpackVector2 | ( | const types::Vector2 & | aInput | ) |
Definition at line 75 of file api_utils.cpp.
Referenced by SCH_LABEL::Deserialize(), SCH_LINE::Deserialize(), PAD::Deserialize(), PADSTACK::Deserialize(), PCB_SHAPE::Deserialize(), and API_HANDLER_EDITOR::handleHitTest().