kicad-python 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- kicad_python-0.1.0.dist-info/LICENSE +674 -0
- kicad_python-0.1.0.dist-info/METADATA +75 -0
- kicad_python-0.1.0.dist-info/RECORD +48 -0
- kicad_python-0.1.0.dist-info/WHEEL +5 -0
- kicad_python-0.1.0.dist-info/top_level.txt +1 -0
- kipy/__init__.py +20 -0
- kipy/board.py +467 -0
- kipy/board_types.py +1800 -0
- kipy/client.py +88 -0
- kipy/common_types.py +842 -0
- kipy/errors.py +37 -0
- kipy/geometry.py +604 -0
- kipy/kicad.py +176 -0
- kipy/project.py +71 -0
- kipy/project_types.py +28 -0
- kipy/proto/__init__.py +20 -0
- kipy/proto/board/__init__.py +20 -0
- kipy/proto/board/board_commands_pb2.py +56 -0
- kipy/proto/board/board_commands_pb2.pyi +487 -0
- kipy/proto/board/board_pb2.py +44 -0
- kipy/proto/board/board_pb2.pyi +294 -0
- kipy/proto/board/board_types_pb2.py +150 -0
- kipy/proto/board/board_types_pb2.pyi +2101 -0
- kipy/proto/common/__init__.py +23 -0
- kipy/proto/common/commands/__init__.py +21 -0
- kipy/proto/common/commands/base_commands_pb2.py +31 -0
- kipy/proto/common/commands/base_commands_pb2.pyi +172 -0
- kipy/proto/common/commands/editor_commands_pb2.py +91 -0
- kipy/proto/common/commands/editor_commands_pb2.pyi +814 -0
- kipy/proto/common/commands/project_commands_pb2.py +24 -0
- kipy/proto/common/commands/project_commands_pb2.pyi +93 -0
- kipy/proto/common/envelope_pb2.py +27 -0
- kipy/proto/common/envelope_pb2.pyi +188 -0
- kipy/proto/common/types/__init__.py +22 -0
- kipy/proto/common/types/base_types_pb2.py +100 -0
- kipy/proto/common/types/base_types_pb2.pyi +1058 -0
- kipy/proto/common/types/enums_pb2.py +22 -0
- kipy/proto/common/types/enums_pb2.pyi +189 -0
- kipy/proto/common/types/project_settings_pb2.py +16 -0
- kipy/proto/common/types/project_settings_pb2.pyi +26 -0
- kipy/proto/schematic/schematic_commands_pb2.py +14 -0
- kipy/proto/schematic/schematic_commands_pb2.pyi +23 -0
- kipy/proto/schematic/schematic_types_pb2.py +29 -0
- kipy/proto/schematic/schematic_types_pb2.pyi +214 -0
- kipy/util/__init__.py +21 -0
- kipy/util/proto.py +61 -0
- kipy/util/units.py +31 -0
- kipy/wrapper.py +35 -0
kipy/wrapper.py
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# This program source code file is part of KiCad, a free EDA CAD application.
|
|
2
|
+
#
|
|
3
|
+
# Copyright (C) 2024 KiCad Developers
|
|
4
|
+
#
|
|
5
|
+
# This program is free software: you can redistribute it and/or modify it
|
|
6
|
+
# under the terms of the GNU General Public License as published by the
|
|
7
|
+
# Free Software Foundation, either version 3 of the License, or (at your
|
|
8
|
+
# option) any later version.
|
|
9
|
+
#
|
|
10
|
+
# This program is distributed in the hope that it will be useful, but
|
|
11
|
+
# WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
12
|
+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
13
|
+
# General Public License for more details.
|
|
14
|
+
#
|
|
15
|
+
# You should have received a copy of the GNU General Public License along
|
|
16
|
+
# with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
17
|
+
|
|
18
|
+
from abc import ABC, abstractmethod
|
|
19
|
+
|
|
20
|
+
from google.protobuf.message import Message
|
|
21
|
+
from kipy.proto.common.types.base_types_pb2 import KIID
|
|
22
|
+
|
|
23
|
+
class Wrapper(ABC):
|
|
24
|
+
def __init__(self, proto: Message):
|
|
25
|
+
pass
|
|
26
|
+
|
|
27
|
+
@property
|
|
28
|
+
def proto(self):
|
|
29
|
+
return self.__dict__['_proto']
|
|
30
|
+
|
|
31
|
+
class Item(Wrapper):
|
|
32
|
+
@property
|
|
33
|
+
@abstractmethod
|
|
34
|
+
def id(self) -> KIID:
|
|
35
|
+
return KIID()
|