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.
Files changed (48) hide show
  1. kicad_python-0.1.0.dist-info/LICENSE +674 -0
  2. kicad_python-0.1.0.dist-info/METADATA +75 -0
  3. kicad_python-0.1.0.dist-info/RECORD +48 -0
  4. kicad_python-0.1.0.dist-info/WHEEL +5 -0
  5. kicad_python-0.1.0.dist-info/top_level.txt +1 -0
  6. kipy/__init__.py +20 -0
  7. kipy/board.py +467 -0
  8. kipy/board_types.py +1800 -0
  9. kipy/client.py +88 -0
  10. kipy/common_types.py +842 -0
  11. kipy/errors.py +37 -0
  12. kipy/geometry.py +604 -0
  13. kipy/kicad.py +176 -0
  14. kipy/project.py +71 -0
  15. kipy/project_types.py +28 -0
  16. kipy/proto/__init__.py +20 -0
  17. kipy/proto/board/__init__.py +20 -0
  18. kipy/proto/board/board_commands_pb2.py +56 -0
  19. kipy/proto/board/board_commands_pb2.pyi +487 -0
  20. kipy/proto/board/board_pb2.py +44 -0
  21. kipy/proto/board/board_pb2.pyi +294 -0
  22. kipy/proto/board/board_types_pb2.py +150 -0
  23. kipy/proto/board/board_types_pb2.pyi +2101 -0
  24. kipy/proto/common/__init__.py +23 -0
  25. kipy/proto/common/commands/__init__.py +21 -0
  26. kipy/proto/common/commands/base_commands_pb2.py +31 -0
  27. kipy/proto/common/commands/base_commands_pb2.pyi +172 -0
  28. kipy/proto/common/commands/editor_commands_pb2.py +91 -0
  29. kipy/proto/common/commands/editor_commands_pb2.pyi +814 -0
  30. kipy/proto/common/commands/project_commands_pb2.py +24 -0
  31. kipy/proto/common/commands/project_commands_pb2.pyi +93 -0
  32. kipy/proto/common/envelope_pb2.py +27 -0
  33. kipy/proto/common/envelope_pb2.pyi +188 -0
  34. kipy/proto/common/types/__init__.py +22 -0
  35. kipy/proto/common/types/base_types_pb2.py +100 -0
  36. kipy/proto/common/types/base_types_pb2.pyi +1058 -0
  37. kipy/proto/common/types/enums_pb2.py +22 -0
  38. kipy/proto/common/types/enums_pb2.pyi +189 -0
  39. kipy/proto/common/types/project_settings_pb2.py +16 -0
  40. kipy/proto/common/types/project_settings_pb2.pyi +26 -0
  41. kipy/proto/schematic/schematic_commands_pb2.py +14 -0
  42. kipy/proto/schematic/schematic_commands_pb2.pyi +23 -0
  43. kipy/proto/schematic/schematic_types_pb2.py +29 -0
  44. kipy/proto/schematic/schematic_types_pb2.pyi +214 -0
  45. kipy/util/__init__.py +21 -0
  46. kipy/util/proto.py +61 -0
  47. kipy/util/units.py +31 -0
  48. kipy/wrapper.py +35 -0
@@ -0,0 +1,814 @@
1
+ """
2
+ @generated by mypy-protobuf. Do not edit manually!
3
+ isort:skip_file
4
+
5
+ Commands and responses related to manipulating editor windows
6
+ """
7
+ import builtins
8
+ import collections.abc
9
+ from ... import common
10
+ import google.protobuf.any_pb2
11
+ import google.protobuf.descriptor
12
+ import google.protobuf.internal.containers
13
+ import google.protobuf.internal.enum_type_wrapper
14
+ import google.protobuf.message
15
+ import sys
16
+ import typing
17
+ if sys.version_info >= (3, 10):
18
+ import typing as typing_extensions
19
+ else:
20
+ import typing_extensions
21
+ DESCRIPTOR: google.protobuf.descriptor.FileDescriptor
22
+
23
+ class _RunActionStatus:
24
+ ValueType = typing.NewType('ValueType', builtins.int)
25
+ V: typing_extensions.TypeAlias = ValueType
26
+
27
+ class _RunActionStatusEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_RunActionStatus.ValueType], builtins.type):
28
+ DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
29
+ RAS_UNKNOWN: _RunActionStatus.ValueType
30
+ RAS_OK: _RunActionStatus.ValueType
31
+ 'The action was submitted successfully.'
32
+ RAS_INVALID: _RunActionStatus.ValueType
33
+ 'The action was unknown for the targeted frame.'
34
+ RAS_FRAME_NOT_OPEN: _RunActionStatus.ValueType
35
+ 'The targeted frame was not open when the call was submitted.'
36
+
37
+ class RunActionStatus(_RunActionStatus, metaclass=_RunActionStatusEnumTypeWrapper):
38
+ ...
39
+ RAS_UNKNOWN: RunActionStatus.ValueType
40
+ RAS_OK: RunActionStatus.ValueType
41
+ 'The action was submitted successfully.'
42
+ RAS_INVALID: RunActionStatus.ValueType
43
+ 'The action was unknown for the targeted frame.'
44
+ RAS_FRAME_NOT_OPEN: RunActionStatus.ValueType
45
+ 'The targeted frame was not open when the call was submitted.'
46
+ global___RunActionStatus = RunActionStatus
47
+
48
+ class _CommitAction:
49
+ ValueType = typing.NewType('ValueType', builtins.int)
50
+ V: typing_extensions.TypeAlias = ValueType
51
+
52
+ class _CommitActionEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_CommitAction.ValueType], builtins.type):
53
+ DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
54
+ CMA_UNKNOWN: _CommitAction.ValueType
55
+ CMA_COMMIT: _CommitAction.ValueType
56
+ 'Commit the changes to the design'
57
+ CMA_DROP: _CommitAction.ValueType
58
+ 'Cancel this commit'
59
+
60
+ class CommitAction(_CommitAction, metaclass=_CommitActionEnumTypeWrapper):
61
+ ...
62
+ CMA_UNKNOWN: CommitAction.ValueType
63
+ CMA_COMMIT: CommitAction.ValueType
64
+ 'Commit the changes to the design'
65
+ CMA_DROP: CommitAction.ValueType
66
+ 'Cancel this commit'
67
+ global___CommitAction = CommitAction
68
+
69
+ class _ItemStatusCode:
70
+ ValueType = typing.NewType('ValueType', builtins.int)
71
+ V: typing_extensions.TypeAlias = ValueType
72
+
73
+ class _ItemStatusCodeEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_ItemStatusCode.ValueType], builtins.type):
74
+ DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
75
+ ISC_UNKNOWN: _ItemStatusCode.ValueType
76
+ ISC_OK: _ItemStatusCode.ValueType
77
+ 'The item was created or updated'
78
+ ISC_INVALID_TYPE: _ItemStatusCode.ValueType
79
+ "The item's type is not valid for the given document"
80
+ ISC_EXISTING: _ItemStatusCode.ValueType
81
+ 'The item to be created had a specified KIID and that KIID was already in use'
82
+ ISC_NONEXISTENT: _ItemStatusCode.ValueType
83
+ 'The item to be updated did not exist in the given document'
84
+ ISC_IMMUTABLE: _ItemStatusCode.ValueType
85
+ 'The item to be updated is not allowed to be modified by the API'
86
+ ISC_INVALID_DATA: _ItemStatusCode.ValueType
87
+ 'The item to be created does not have valid data for the given document'
88
+
89
+ class ItemStatusCode(_ItemStatusCode, metaclass=_ItemStatusCodeEnumTypeWrapper):
90
+ ...
91
+ ISC_UNKNOWN: ItemStatusCode.ValueType
92
+ ISC_OK: ItemStatusCode.ValueType
93
+ 'The item was created or updated'
94
+ ISC_INVALID_TYPE: ItemStatusCode.ValueType
95
+ "The item's type is not valid for the given document"
96
+ ISC_EXISTING: ItemStatusCode.ValueType
97
+ 'The item to be created had a specified KIID and that KIID was already in use'
98
+ ISC_NONEXISTENT: ItemStatusCode.ValueType
99
+ 'The item to be updated did not exist in the given document'
100
+ ISC_IMMUTABLE: ItemStatusCode.ValueType
101
+ 'The item to be updated is not allowed to be modified by the API'
102
+ ISC_INVALID_DATA: ItemStatusCode.ValueType
103
+ 'The item to be created does not have valid data for the given document'
104
+ global___ItemStatusCode = ItemStatusCode
105
+
106
+ class _ItemDeletionStatus:
107
+ ValueType = typing.NewType('ValueType', builtins.int)
108
+ V: typing_extensions.TypeAlias = ValueType
109
+
110
+ class _ItemDeletionStatusEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_ItemDeletionStatus.ValueType], builtins.type):
111
+ DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
112
+ IDS_UNKNOWN: _ItemDeletionStatus.ValueType
113
+ IDS_OK: _ItemDeletionStatus.ValueType
114
+ IDS_NONEXISTENT: _ItemDeletionStatus.ValueType
115
+ 'The item did not exist in the given document'
116
+ IDS_IMMUTABLE: _ItemDeletionStatus.ValueType
117
+ 'The item is not allowed to be modified by the API'
118
+
119
+ class ItemDeletionStatus(_ItemDeletionStatus, metaclass=_ItemDeletionStatusEnumTypeWrapper):
120
+ ...
121
+ IDS_UNKNOWN: ItemDeletionStatus.ValueType
122
+ IDS_OK: ItemDeletionStatus.ValueType
123
+ IDS_NONEXISTENT: ItemDeletionStatus.ValueType
124
+ 'The item did not exist in the given document'
125
+ IDS_IMMUTABLE: ItemDeletionStatus.ValueType
126
+ 'The item is not allowed to be modified by the API'
127
+ global___ItemDeletionStatus = ItemDeletionStatus
128
+
129
+ class _BoundingBoxMode:
130
+ ValueType = typing.NewType('ValueType', builtins.int)
131
+ V: typing_extensions.TypeAlias = ValueType
132
+
133
+ class _BoundingBoxModeEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_BoundingBoxMode.ValueType], builtins.type):
134
+ DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
135
+ BBM_UNKNOWN: _BoundingBoxMode.ValueType
136
+ BBM_ITEM_ONLY: _BoundingBoxMode.ValueType
137
+ BBM_ITEM_AND_CHILD_TEXT: _BoundingBoxMode.ValueType
138
+
139
+ class BoundingBoxMode(_BoundingBoxMode, metaclass=_BoundingBoxModeEnumTypeWrapper):
140
+ ...
141
+ BBM_UNKNOWN: BoundingBoxMode.ValueType
142
+ BBM_ITEM_ONLY: BoundingBoxMode.ValueType
143
+ BBM_ITEM_AND_CHILD_TEXT: BoundingBoxMode.ValueType
144
+ global___BoundingBoxMode = BoundingBoxMode
145
+
146
+ class _HitTestResult:
147
+ ValueType = typing.NewType('ValueType', builtins.int)
148
+ V: typing_extensions.TypeAlias = ValueType
149
+
150
+ class _HitTestResultEnumTypeWrapper(google.protobuf.internal.enum_type_wrapper._EnumTypeWrapper[_HitTestResult.ValueType], builtins.type):
151
+ DESCRIPTOR: google.protobuf.descriptor.EnumDescriptor
152
+ HTR_UNKNOWN: _HitTestResult.ValueType
153
+ HTR_NO_HIT: _HitTestResult.ValueType
154
+ HTR_HIT: _HitTestResult.ValueType
155
+
156
+ class HitTestResult(_HitTestResult, metaclass=_HitTestResultEnumTypeWrapper):
157
+ ...
158
+ HTR_UNKNOWN: HitTestResult.ValueType
159
+ HTR_NO_HIT: HitTestResult.ValueType
160
+ HTR_HIT: HitTestResult.ValueType
161
+ global___HitTestResult = HitTestResult
162
+
163
+ @typing.final
164
+ class RefreshEditor(google.protobuf.message.Message):
165
+ """Refreshes the given frame, if that frame is open"""
166
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
167
+ FRAME_FIELD_NUMBER: builtins.int
168
+ frame: common.types.base_types_pb2.FrameType.ValueType
169
+
170
+ def __init__(self, *, frame: common.types.base_types_pb2.FrameType.ValueType=...) -> None:
171
+ ...
172
+
173
+ def ClearField(self, field_name: typing.Literal['frame', b'frame']) -> None:
174
+ ...
175
+ global___RefreshEditor = RefreshEditor
176
+
177
+ @typing.final
178
+ class GetOpenDocuments(google.protobuf.message.Message):
179
+ """Retrieves a list of open documents of the given type"""
180
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
181
+ TYPE_FIELD_NUMBER: builtins.int
182
+ type: common.types.base_types_pb2.DocumentType.ValueType
183
+ 'Which type of documents to query'
184
+
185
+ def __init__(self, *, type: common.types.base_types_pb2.DocumentType.ValueType=...) -> None:
186
+ ...
187
+
188
+ def ClearField(self, field_name: typing.Literal['type', b'type']) -> None:
189
+ ...
190
+ global___GetOpenDocuments = GetOpenDocuments
191
+
192
+ @typing.final
193
+ class GetOpenDocumentsResponse(google.protobuf.message.Message):
194
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
195
+ DOCUMENTS_FIELD_NUMBER: builtins.int
196
+
197
+ @property
198
+ def documents(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[common.types.base_types_pb2.DocumentSpecifier]:
199
+ ...
200
+
201
+ def __init__(self, *, documents: collections.abc.Iterable[common.types.base_types_pb2.DocumentSpecifier] | None=...) -> None:
202
+ ...
203
+
204
+ def ClearField(self, field_name: typing.Literal['documents', b'documents']) -> None:
205
+ ...
206
+ global___GetOpenDocumentsResponse = GetOpenDocumentsResponse
207
+
208
+ @typing.final
209
+ class RunAction(google.protobuf.message.Message):
210
+ """
211
+ Runs a TOOL_ACTION using the TOOL_MANAGER of a given frame.
212
+ WARNING: The TOOL_ACTIONs are specifically *not* an API.
213
+ Command names may change as code is refactored, and commands may disappear.
214
+ This API method is provided for low-level prototyping purposes only.
215
+ """
216
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
217
+ ACTION_FIELD_NUMBER: builtins.int
218
+ action: builtins.str
219
+ 'Action name, like "eeschema.InteractiveSelection.ClearSelection" '
220
+
221
+ def __init__(self, *, action: builtins.str=...) -> None:
222
+ ...
223
+
224
+ def ClearField(self, field_name: typing.Literal['action', b'action']) -> None:
225
+ ...
226
+ global___RunAction = RunAction
227
+
228
+ @typing.final
229
+ class RunActionResponse(google.protobuf.message.Message):
230
+ """
231
+ NOTE: At the moment, RAS_FRAME_NOT_OPEN won't be returned as the handler is inside the frame.
232
+ """
233
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
234
+ STATUS_FIELD_NUMBER: builtins.int
235
+ status: global___RunActionStatus.ValueType
236
+
237
+ def __init__(self, *, status: global___RunActionStatus.ValueType=...) -> None:
238
+ ...
239
+
240
+ def ClearField(self, field_name: typing.Literal['status', b'status']) -> None:
241
+ ...
242
+ global___RunActionResponse = RunActionResponse
243
+
244
+ @typing.final
245
+ class BeginCommit(google.protobuf.message.Message):
246
+ """
247
+ Begins a staged set of changes. Any modifications made to a document through the API after this
248
+ call will be saved to a pending commit, and will not appear in KiCad until a matching call to
249
+ END_COMMIT.
250
+ """
251
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
252
+
253
+ def __init__(self) -> None:
254
+ ...
255
+ global___BeginCommit = BeginCommit
256
+
257
+ @typing.final
258
+ class BeginCommitResponse(google.protobuf.message.Message):
259
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
260
+ ID_FIELD_NUMBER: builtins.int
261
+
262
+ @property
263
+ def id(self) -> common.types.base_types_pb2.KIID:
264
+ """Opaque identifier tracking a commit"""
265
+
266
+ def __init__(self, *, id: common.types.base_types_pb2.KIID | None=...) -> None:
267
+ ...
268
+
269
+ def HasField(self, field_name: typing.Literal['id', b'id']) -> builtins.bool:
270
+ ...
271
+
272
+ def ClearField(self, field_name: typing.Literal['id', b'id']) -> None:
273
+ ...
274
+ global___BeginCommitResponse = BeginCommitResponse
275
+
276
+ @typing.final
277
+ class EndCommit(google.protobuf.message.Message):
278
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
279
+ ID_FIELD_NUMBER: builtins.int
280
+ ACTION_FIELD_NUMBER: builtins.int
281
+ MESSAGE_FIELD_NUMBER: builtins.int
282
+ action: global___CommitAction.ValueType
283
+ 'What to do with this commit'
284
+ message: builtins.str
285
+ 'Optional message describing this changeset'
286
+
287
+ @property
288
+ def id(self) -> common.types.base_types_pb2.KIID:
289
+ """The ID that was given by BeginCommit"""
290
+
291
+ def __init__(self, *, id: common.types.base_types_pb2.KIID | None=..., action: global___CommitAction.ValueType=..., message: builtins.str=...) -> None:
292
+ ...
293
+
294
+ def HasField(self, field_name: typing.Literal['id', b'id']) -> builtins.bool:
295
+ ...
296
+
297
+ def ClearField(self, field_name: typing.Literal['action', b'action', 'id', b'id', 'message', b'message']) -> None:
298
+ ...
299
+ global___EndCommit = EndCommit
300
+
301
+ @typing.final
302
+ class EndCommitResponse(google.protobuf.message.Message):
303
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
304
+
305
+ def __init__(self) -> None:
306
+ ...
307
+ global___EndCommitResponse = EndCommitResponse
308
+
309
+ @typing.final
310
+ class CreateItems(google.protobuf.message.Message):
311
+ """Creates new items on a given document"""
312
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
313
+ HEADER_FIELD_NUMBER: builtins.int
314
+ ITEMS_FIELD_NUMBER: builtins.int
315
+ CONTAINER_FIELD_NUMBER: builtins.int
316
+
317
+ @property
318
+ def header(self) -> common.types.base_types_pb2.ItemHeader:
319
+ """Specifies which document to create on, which fields are included, etc."""
320
+
321
+ @property
322
+ def items(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[google.protobuf.any_pb2.Any]:
323
+ """List of items to create"""
324
+
325
+ @property
326
+ def container(self) -> common.types.base_types_pb2.KIID:
327
+ """Items may be created on a top-level document (sheet, board, etc) or inside a container
328
+ (symbol, footprint). If this field is not empty, it holds the ID of a symbol or footprint
329
+ that the items should be added to. This ID must be an existing symbol (for schematic
330
+ documents) or footprint (for board documents). If the given container does not exist or is
331
+ not the correct item type, the CreateItems call will fail.
332
+ """
333
+
334
+ def __init__(self, *, header: common.types.base_types_pb2.ItemHeader | None=..., items: collections.abc.Iterable[google.protobuf.any_pb2.Any] | None=..., container: common.types.base_types_pb2.KIID | None=...) -> None:
335
+ ...
336
+
337
+ def HasField(self, field_name: typing.Literal['container', b'container', 'header', b'header']) -> builtins.bool:
338
+ ...
339
+
340
+ def ClearField(self, field_name: typing.Literal['container', b'container', 'header', b'header', 'items', b'items']) -> None:
341
+ ...
342
+ global___CreateItems = CreateItems
343
+
344
+ @typing.final
345
+ class ItemStatus(google.protobuf.message.Message):
346
+ """Per-item status feedback for creation and update calls"""
347
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
348
+ CODE_FIELD_NUMBER: builtins.int
349
+ ERROR_MESSAGE_FIELD_NUMBER: builtins.int
350
+ code: global___ItemStatusCode.ValueType
351
+ error_message: builtins.str
352
+
353
+ def __init__(self, *, code: global___ItemStatusCode.ValueType=..., error_message: builtins.str=...) -> None:
354
+ ...
355
+
356
+ def ClearField(self, field_name: typing.Literal['code', b'code', 'error_message', b'error_message']) -> None:
357
+ ...
358
+ global___ItemStatus = ItemStatus
359
+
360
+ @typing.final
361
+ class ItemCreationResult(google.protobuf.message.Message):
362
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
363
+ STATUS_FIELD_NUMBER: builtins.int
364
+ ITEM_FIELD_NUMBER: builtins.int
365
+
366
+ @property
367
+ def status(self) -> global___ItemStatus:
368
+ ...
369
+
370
+ @property
371
+ def item(self) -> google.protobuf.any_pb2.Any:
372
+ """The created version of the item, including an updated KIID as applicable"""
373
+
374
+ def __init__(self, *, status: global___ItemStatus | None=..., item: google.protobuf.any_pb2.Any | None=...) -> None:
375
+ ...
376
+
377
+ def HasField(self, field_name: typing.Literal['item', b'item', 'status', b'status']) -> builtins.bool:
378
+ ...
379
+
380
+ def ClearField(self, field_name: typing.Literal['item', b'item', 'status', b'status']) -> None:
381
+ ...
382
+ global___ItemCreationResult = ItemCreationResult
383
+
384
+ @typing.final
385
+ class CreateItemsResponse(google.protobuf.message.Message):
386
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
387
+ HEADER_FIELD_NUMBER: builtins.int
388
+ STATUS_FIELD_NUMBER: builtins.int
389
+ CREATED_ITEMS_FIELD_NUMBER: builtins.int
390
+ status: common.types.base_types_pb2.ItemRequestStatus.ValueType
391
+ 'Status of the overall request; may return IRS_OK even if no items were created'
392
+
393
+ @property
394
+ def header(self) -> common.types.base_types_pb2.ItemHeader:
395
+ """Specifies which document was modified, which fields are included in created_items, etc."""
396
+
397
+ @property
398
+ def created_items(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ItemCreationResult]:
399
+ """Status of each item to be created"""
400
+
401
+ def __init__(self, *, header: common.types.base_types_pb2.ItemHeader | None=..., status: common.types.base_types_pb2.ItemRequestStatus.ValueType=..., created_items: collections.abc.Iterable[global___ItemCreationResult] | None=...) -> None:
402
+ ...
403
+
404
+ def HasField(self, field_name: typing.Literal['header', b'header']) -> builtins.bool:
405
+ ...
406
+
407
+ def ClearField(self, field_name: typing.Literal['created_items', b'created_items', 'header', b'header', 'status', b'status']) -> None:
408
+ ...
409
+ global___CreateItemsResponse = CreateItemsResponse
410
+
411
+ @typing.final
412
+ class GetItems(google.protobuf.message.Message):
413
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
414
+ HEADER_FIELD_NUMBER: builtins.int
415
+ TYPES_FIELD_NUMBER: builtins.int
416
+
417
+ @property
418
+ def header(self) -> common.types.base_types_pb2.ItemHeader:
419
+ """Specifies which document to query, which fields to return, etc."""
420
+
421
+ @property
422
+ def types(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[common.types.enums_pb2.KiCadObjectType.ValueType]:
423
+ """List of one or more types of items to retreive"""
424
+
425
+ def __init__(self, *, header: common.types.base_types_pb2.ItemHeader | None=..., types: collections.abc.Iterable[common.types.enums_pb2.KiCadObjectType.ValueType] | None=...) -> None:
426
+ ...
427
+
428
+ def HasField(self, field_name: typing.Literal['header', b'header']) -> builtins.bool:
429
+ ...
430
+
431
+ def ClearField(self, field_name: typing.Literal['header', b'header', 'types', b'types']) -> None:
432
+ ...
433
+ global___GetItems = GetItems
434
+
435
+ @typing.final
436
+ class GetItemsResponse(google.protobuf.message.Message):
437
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
438
+ HEADER_FIELD_NUMBER: builtins.int
439
+ STATUS_FIELD_NUMBER: builtins.int
440
+ ITEMS_FIELD_NUMBER: builtins.int
441
+ status: common.types.base_types_pb2.ItemRequestStatus.ValueType
442
+ 'Status of the overall request; may return IRS_OK even if no items were retrieved'
443
+
444
+ @property
445
+ def header(self) -> common.types.base_types_pb2.ItemHeader:
446
+ """Specifies which document was modified, which fields are included in items, etc."""
447
+
448
+ @property
449
+ def items(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[google.protobuf.any_pb2.Any]:
450
+ ...
451
+
452
+ def __init__(self, *, header: common.types.base_types_pb2.ItemHeader | None=..., status: common.types.base_types_pb2.ItemRequestStatus.ValueType=..., items: collections.abc.Iterable[google.protobuf.any_pb2.Any] | None=...) -> None:
453
+ ...
454
+
455
+ def HasField(self, field_name: typing.Literal['header', b'header']) -> builtins.bool:
456
+ ...
457
+
458
+ def ClearField(self, field_name: typing.Literal['header', b'header', 'items', b'items', 'status', b'status']) -> None:
459
+ ...
460
+ global___GetItemsResponse = GetItemsResponse
461
+
462
+ @typing.final
463
+ class UpdateItems(google.protobuf.message.Message):
464
+ """Updates items in a given document"""
465
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
466
+ HEADER_FIELD_NUMBER: builtins.int
467
+ ITEMS_FIELD_NUMBER: builtins.int
468
+
469
+ @property
470
+ def header(self) -> common.types.base_types_pb2.ItemHeader:
471
+ """Specifies which document to modify, which fields are included, etc."""
472
+
473
+ @property
474
+ def items(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[google.protobuf.any_pb2.Any]:
475
+ """List of items to modify"""
476
+
477
+ def __init__(self, *, header: common.types.base_types_pb2.ItemHeader | None=..., items: collections.abc.Iterable[google.protobuf.any_pb2.Any] | None=...) -> None:
478
+ ...
479
+
480
+ def HasField(self, field_name: typing.Literal['header', b'header']) -> builtins.bool:
481
+ ...
482
+
483
+ def ClearField(self, field_name: typing.Literal['header', b'header', 'items', b'items']) -> None:
484
+ ...
485
+ global___UpdateItems = UpdateItems
486
+
487
+ @typing.final
488
+ class ItemUpdateResult(google.protobuf.message.Message):
489
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
490
+ STATUS_FIELD_NUMBER: builtins.int
491
+ ITEM_FIELD_NUMBER: builtins.int
492
+
493
+ @property
494
+ def status(self) -> global___ItemStatus:
495
+ ...
496
+
497
+ @property
498
+ def item(self) -> google.protobuf.any_pb2.Any:
499
+ """The update version of the item"""
500
+
501
+ def __init__(self, *, status: global___ItemStatus | None=..., item: google.protobuf.any_pb2.Any | None=...) -> None:
502
+ ...
503
+
504
+ def HasField(self, field_name: typing.Literal['item', b'item', 'status', b'status']) -> builtins.bool:
505
+ ...
506
+
507
+ def ClearField(self, field_name: typing.Literal['item', b'item', 'status', b'status']) -> None:
508
+ ...
509
+ global___ItemUpdateResult = ItemUpdateResult
510
+
511
+ @typing.final
512
+ class UpdateItemsResponse(google.protobuf.message.Message):
513
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
514
+ HEADER_FIELD_NUMBER: builtins.int
515
+ STATUS_FIELD_NUMBER: builtins.int
516
+ UPDATED_ITEMS_FIELD_NUMBER: builtins.int
517
+ status: common.types.base_types_pb2.ItemRequestStatus.ValueType
518
+ 'Status of the overall request; may return IRS_OK even if no items were modified'
519
+
520
+ @property
521
+ def header(self) -> common.types.base_types_pb2.ItemHeader:
522
+ """Specifies which document was modified, which fields are included in updated_items, etc."""
523
+
524
+ @property
525
+ def updated_items(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ItemUpdateResult]:
526
+ """Status of each item to be created"""
527
+
528
+ def __init__(self, *, header: common.types.base_types_pb2.ItemHeader | None=..., status: common.types.base_types_pb2.ItemRequestStatus.ValueType=..., updated_items: collections.abc.Iterable[global___ItemUpdateResult] | None=...) -> None:
529
+ ...
530
+
531
+ def HasField(self, field_name: typing.Literal['header', b'header']) -> builtins.bool:
532
+ ...
533
+
534
+ def ClearField(self, field_name: typing.Literal['header', b'header', 'status', b'status', 'updated_items', b'updated_items']) -> None:
535
+ ...
536
+ global___UpdateItemsResponse = UpdateItemsResponse
537
+
538
+ @typing.final
539
+ class DeleteItems(google.protobuf.message.Message):
540
+ """Deletes items in a given document"""
541
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
542
+ HEADER_FIELD_NUMBER: builtins.int
543
+ ITEM_IDS_FIELD_NUMBER: builtins.int
544
+
545
+ @property
546
+ def header(self) -> common.types.base_types_pb2.ItemHeader:
547
+ """Specifies which document to modify"""
548
+
549
+ @property
550
+ def item_ids(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[common.types.base_types_pb2.KIID]:
551
+ """List of item KIIDs to delete"""
552
+
553
+ def __init__(self, *, header: common.types.base_types_pb2.ItemHeader | None=..., item_ids: collections.abc.Iterable[common.types.base_types_pb2.KIID] | None=...) -> None:
554
+ ...
555
+
556
+ def HasField(self, field_name: typing.Literal['header', b'header']) -> builtins.bool:
557
+ ...
558
+
559
+ def ClearField(self, field_name: typing.Literal['header', b'header', 'item_ids', b'item_ids']) -> None:
560
+ ...
561
+ global___DeleteItems = DeleteItems
562
+
563
+ @typing.final
564
+ class ItemDeletionResult(google.protobuf.message.Message):
565
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
566
+ ID_FIELD_NUMBER: builtins.int
567
+ STATUS_FIELD_NUMBER: builtins.int
568
+ status: global___ItemDeletionStatus.ValueType
569
+
570
+ @property
571
+ def id(self) -> common.types.base_types_pb2.KIID:
572
+ ...
573
+
574
+ def __init__(self, *, id: common.types.base_types_pb2.KIID | None=..., status: global___ItemDeletionStatus.ValueType=...) -> None:
575
+ ...
576
+
577
+ def HasField(self, field_name: typing.Literal['id', b'id']) -> builtins.bool:
578
+ ...
579
+
580
+ def ClearField(self, field_name: typing.Literal['id', b'id', 'status', b'status']) -> None:
581
+ ...
582
+ global___ItemDeletionResult = ItemDeletionResult
583
+
584
+ @typing.final
585
+ class DeleteItemsResponse(google.protobuf.message.Message):
586
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
587
+ HEADER_FIELD_NUMBER: builtins.int
588
+ STATUS_FIELD_NUMBER: builtins.int
589
+ DELETED_ITEMS_FIELD_NUMBER: builtins.int
590
+ status: common.types.base_types_pb2.ItemRequestStatus.ValueType
591
+ 'Status of the overall request; may return IRS_OK even if no items were deleted'
592
+
593
+ @property
594
+ def header(self) -> common.types.base_types_pb2.ItemHeader:
595
+ """Specifies which document was modified, etc."""
596
+
597
+ @property
598
+ def deleted_items(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ItemDeletionResult]:
599
+ """Status of each item requested to be deleted"""
600
+
601
+ def __init__(self, *, header: common.types.base_types_pb2.ItemHeader | None=..., status: common.types.base_types_pb2.ItemRequestStatus.ValueType=..., deleted_items: collections.abc.Iterable[global___ItemDeletionResult] | None=...) -> None:
602
+ ...
603
+
604
+ def HasField(self, field_name: typing.Literal['header', b'header']) -> builtins.bool:
605
+ ...
606
+
607
+ def ClearField(self, field_name: typing.Literal['deleted_items', b'deleted_items', 'header', b'header', 'status', b'status']) -> None:
608
+ ...
609
+ global___DeleteItemsResponse = DeleteItemsResponse
610
+
611
+ @typing.final
612
+ class GetBoundingBox(google.protobuf.message.Message):
613
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
614
+ HEADER_FIELD_NUMBER: builtins.int
615
+ ITEMS_FIELD_NUMBER: builtins.int
616
+ MODE_FIELD_NUMBER: builtins.int
617
+ mode: global___BoundingBoxMode.ValueType
618
+ 'Some item types can have independently-movable text as children (e.g. footprints)\n This mode controls whether or not these are included in the box\n '
619
+
620
+ @property
621
+ def header(self) -> common.types.base_types_pb2.ItemHeader:
622
+ ...
623
+
624
+ @property
625
+ def items(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[common.types.base_types_pb2.KIID]:
626
+ ...
627
+
628
+ def __init__(self, *, header: common.types.base_types_pb2.ItemHeader | None=..., items: collections.abc.Iterable[common.types.base_types_pb2.KIID] | None=..., mode: global___BoundingBoxMode.ValueType=...) -> None:
629
+ ...
630
+
631
+ def HasField(self, field_name: typing.Literal['header', b'header']) -> builtins.bool:
632
+ ...
633
+
634
+ def ClearField(self, field_name: typing.Literal['header', b'header', 'items', b'items', 'mode', b'mode']) -> None:
635
+ ...
636
+ global___GetBoundingBox = GetBoundingBox
637
+
638
+ @typing.final
639
+ class GetBoundingBoxResponse(google.protobuf.message.Message):
640
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
641
+ ITEMS_FIELD_NUMBER: builtins.int
642
+ BOXES_FIELD_NUMBER: builtins.int
643
+
644
+ @property
645
+ def items(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[common.types.base_types_pb2.KIID]:
646
+ ...
647
+
648
+ @property
649
+ def boxes(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[common.types.base_types_pb2.Box2]:
650
+ ...
651
+
652
+ def __init__(self, *, items: collections.abc.Iterable[common.types.base_types_pb2.KIID] | None=..., boxes: collections.abc.Iterable[common.types.base_types_pb2.Box2] | None=...) -> None:
653
+ ...
654
+
655
+ def ClearField(self, field_name: typing.Literal['boxes', b'boxes', 'items', b'items']) -> None:
656
+ ...
657
+ global___GetBoundingBoxResponse = GetBoundingBoxResponse
658
+
659
+ @typing.final
660
+ class HitTest(google.protobuf.message.Message):
661
+ """Tests if a certain point falls within tolerance of an item's geometry"""
662
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
663
+ HEADER_FIELD_NUMBER: builtins.int
664
+ ID_FIELD_NUMBER: builtins.int
665
+ POSITION_FIELD_NUMBER: builtins.int
666
+ TOLERANCE_FIELD_NUMBER: builtins.int
667
+ tolerance: builtins.int
668
+
669
+ @property
670
+ def header(self) -> common.types.base_types_pb2.ItemHeader:
671
+ ...
672
+
673
+ @property
674
+ def id(self) -> common.types.base_types_pb2.KIID:
675
+ ...
676
+
677
+ @property
678
+ def position(self) -> common.types.base_types_pb2.Vector2:
679
+ ...
680
+
681
+ def __init__(self, *, header: common.types.base_types_pb2.ItemHeader | None=..., id: common.types.base_types_pb2.KIID | None=..., position: common.types.base_types_pb2.Vector2 | None=..., tolerance: builtins.int=...) -> None:
682
+ ...
683
+
684
+ def HasField(self, field_name: typing.Literal['header', b'header', 'id', b'id', 'position', b'position']) -> builtins.bool:
685
+ ...
686
+
687
+ def ClearField(self, field_name: typing.Literal['header', b'header', 'id', b'id', 'position', b'position', 'tolerance', b'tolerance']) -> None:
688
+ ...
689
+ global___HitTest = HitTest
690
+
691
+ @typing.final
692
+ class HitTestResponse(google.protobuf.message.Message):
693
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
694
+ RESULT_FIELD_NUMBER: builtins.int
695
+ result: global___HitTestResult.ValueType
696
+
697
+ def __init__(self, *, result: global___HitTestResult.ValueType=...) -> None:
698
+ ...
699
+
700
+ def ClearField(self, field_name: typing.Literal['result', b'result']) -> None:
701
+ ...
702
+ global___HitTestResponse = HitTestResponse
703
+
704
+ @typing.final
705
+ class GetTitleBlockInfo(google.protobuf.message.Message):
706
+ """returns common.types.TitleBlockInfo"""
707
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
708
+ DOCUMENT_FIELD_NUMBER: builtins.int
709
+
710
+ @property
711
+ def document(self) -> common.types.base_types_pb2.DocumentSpecifier:
712
+ ...
713
+
714
+ def __init__(self, *, document: common.types.base_types_pb2.DocumentSpecifier | None=...) -> None:
715
+ ...
716
+
717
+ def HasField(self, field_name: typing.Literal['document', b'document']) -> builtins.bool:
718
+ ...
719
+
720
+ def ClearField(self, field_name: typing.Literal['document', b'document']) -> None:
721
+ ...
722
+ global___GetTitleBlockInfo = GetTitleBlockInfo
723
+
724
+ @typing.final
725
+ class SaveDocumentToString(google.protobuf.message.Message):
726
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
727
+ DOCUMENT_FIELD_NUMBER: builtins.int
728
+
729
+ @property
730
+ def document(self) -> common.types.base_types_pb2.DocumentSpecifier:
731
+ ...
732
+
733
+ def __init__(self, *, document: common.types.base_types_pb2.DocumentSpecifier | None=...) -> None:
734
+ ...
735
+
736
+ def HasField(self, field_name: typing.Literal['document', b'document']) -> builtins.bool:
737
+ ...
738
+
739
+ def ClearField(self, field_name: typing.Literal['document', b'document']) -> None:
740
+ ...
741
+ global___SaveDocumentToString = SaveDocumentToString
742
+
743
+ @typing.final
744
+ class SavedDocumentResponse(google.protobuf.message.Message):
745
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
746
+ DOCUMENT_FIELD_NUMBER: builtins.int
747
+ CONTENTS_FIELD_NUMBER: builtins.int
748
+ contents: builtins.str
749
+
750
+ @property
751
+ def document(self) -> common.types.base_types_pb2.DocumentSpecifier:
752
+ ...
753
+
754
+ def __init__(self, *, document: common.types.base_types_pb2.DocumentSpecifier | None=..., contents: builtins.str=...) -> None:
755
+ ...
756
+
757
+ def HasField(self, field_name: typing.Literal['document', b'document']) -> builtins.bool:
758
+ ...
759
+
760
+ def ClearField(self, field_name: typing.Literal['contents', b'contents', 'document', b'document']) -> None:
761
+ ...
762
+ global___SavedDocumentResponse = SavedDocumentResponse
763
+
764
+ @typing.final
765
+ class SaveSelectionToString(google.protobuf.message.Message):
766
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
767
+
768
+ def __init__(self) -> None:
769
+ ...
770
+ global___SaveSelectionToString = SaveSelectionToString
771
+
772
+ @typing.final
773
+ class SavedSelectionResponse(google.protobuf.message.Message):
774
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
775
+ IDS_FIELD_NUMBER: builtins.int
776
+ CONTENTS_FIELD_NUMBER: builtins.int
777
+ contents: builtins.str
778
+
779
+ @property
780
+ def ids(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[common.types.base_types_pb2.KIID]:
781
+ ...
782
+
783
+ def __init__(self, *, ids: collections.abc.Iterable[common.types.base_types_pb2.KIID] | None=..., contents: builtins.str=...) -> None:
784
+ ...
785
+
786
+ def ClearField(self, field_name: typing.Literal['contents', b'contents', 'ids', b'ids']) -> None:
787
+ ...
788
+ global___SavedSelectionResponse = SavedSelectionResponse
789
+
790
+ @typing.final
791
+ class ParseAndCreateItemsFromString(google.protobuf.message.Message):
792
+ """Attempts to parse the given string as a s-expression formatted container with items,
793
+ similar to how the Paste action inside the KiCad editor works. If the parse is successful,
794
+ the items will be created and inserted into the editor.
795
+ Returns CreateItemsResponse
796
+ """
797
+ DESCRIPTOR: google.protobuf.descriptor.Descriptor
798
+ DOCUMENT_FIELD_NUMBER: builtins.int
799
+ CONTENTS_FIELD_NUMBER: builtins.int
800
+ contents: builtins.str
801
+
802
+ @property
803
+ def document(self) -> common.types.base_types_pb2.DocumentSpecifier:
804
+ ...
805
+
806
+ def __init__(self, *, document: common.types.base_types_pb2.DocumentSpecifier | None=..., contents: builtins.str=...) -> None:
807
+ ...
808
+
809
+ def HasField(self, field_name: typing.Literal['document', b'document']) -> builtins.bool:
810
+ ...
811
+
812
+ def ClearField(self, field_name: typing.Literal['contents', b'contents', 'document', b'document']) -> None:
813
+ ...
814
+ global___ParseAndCreateItemsFromString = ParseAndCreateItemsFromString