datacom-device-api 0.1.5__tar.gz → 0.1.6__tar.gz

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 (25) hide show
  1. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/PKG-INFO +1 -1
  2. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/pyproject.toml +1 -1
  3. datacom_device_api-0.1.6/src/datacom_device_api/event/event.py +20 -0
  4. datacom_device_api-0.1.6/src/datacom_device_api/ext/ext_meta.py +28 -0
  5. datacom_device_api-0.1.6/src/datacom_device_api/ext/ext_meta_display.py +34 -0
  6. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api.egg-info/PKG-INFO +1 -1
  7. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api.egg-info/SOURCES.txt +3 -0
  8. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/README.md +0 -0
  9. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/setup.cfg +0 -0
  10. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/__init__.py +0 -0
  11. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/data/__init__.py +0 -0
  12. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/data/table.py +0 -0
  13. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/operation/__init__.py +0 -0
  14. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/operation/table_operation.py +0 -0
  15. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/operation/table_read_from_xlsx.py +0 -0
  16. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/operation/table_save_to_db.py +0 -0
  17. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/process/__init__.py +0 -0
  18. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/process/terminal_process.py +0 -0
  19. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/utils/__init__.py +0 -0
  20. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/utils/directory_util.py +0 -0
  21. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api/utils/logger.py +0 -0
  22. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api.egg-info/dependency_links.txt +0 -0
  23. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api.egg-info/requires.txt +0 -0
  24. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/src/datacom_device_api.egg-info/top_level.txt +0 -0
  25. {datacom_device_api-0.1.5 → datacom_device_api-0.1.6}/test/test_table_matching.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: datacom-device-api
3
- Version: 0.1.5
3
+ Version: 0.1.6
4
4
  Summary: Add your description here
5
5
  Requires-Python: >=3.14
6
6
  Description-Content-Type: text/markdown
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "datacom-device-api"
3
- version = "0.1.5"
3
+ version = "0.1.6"
4
4
  description = "Add your description here"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.14"
@@ -0,0 +1,20 @@
1
+ from typing import Callable
2
+
3
+
4
+ class Event:
5
+ def __init__(self) -> None:
6
+ self.__events: dict[str, list[Callable[[], None]]] = {}
7
+
8
+ def reg(self, event: str, func: Callable[[], None]) -> None:
9
+ if event not in self.__events.keys():
10
+ self.__events[event] = []
11
+
12
+ self.__events[event].append(func)
13
+
14
+ def trigger(self, event: str):
15
+ if event not in self.__events.keys():
16
+ return
17
+
18
+ for func in self.__events[event]:
19
+ func()
20
+
@@ -0,0 +1,28 @@
1
+ from dataclasses import dataclass
2
+ from typing import Callable
3
+
4
+ from datacom_device_api.event.event import Event
5
+
6
+
7
+ @dataclass
8
+ class ExtEntry(object):
9
+ version: str
10
+ description: str
11
+ author: str
12
+ license: str
13
+ name: str
14
+
15
+ menu_name: str
16
+ menu_index: int
17
+
18
+ run: Callable[[Event], None]
19
+
20
+ @dataclass
21
+ class ExtMetaInfo:
22
+ VERSION: str = '__version'
23
+ AUTHOR: str = '__author'
24
+ LICENSE: str = '__license'
25
+ NAME: str = '__name'
26
+ MENU_NAME: str = '__menu_name'
27
+ MENU_INDEX: str = '__menu_index'
28
+ DESCRIPTION: str = '__description'
@@ -0,0 +1,34 @@
1
+ from datacom_device_api.event.event import Event
2
+ from dataclasses import dataclass
3
+ from typing import Any, Callable
4
+
5
+
6
+ @dataclass
7
+ class ExtMetaDisplay:
8
+ active: bool
9
+
10
+ """
11
+ init_func: Callable[[Event], Any]
12
+ [
13
+ Event: 'main_program_event_instance'
14
+ ]
15
+ """
16
+ init_func: Callable[[Event], Any]
17
+
18
+ """
19
+ reg_windows_instance_func: Callable[[], Any]
20
+ return '返回注册的窗口实例'
21
+ """
22
+ reg_windows_instance_func: Callable[[], Any]
23
+
24
+ """
25
+ ext_event_func: Callable[[], Event]
26
+ return '返回扩展的事件实例'
27
+ """
28
+ ext_event_func: Callable[[], Event]
29
+
30
+ """
31
+ close_func: Callable[[], Any]
32
+ return '关闭扩展的显示'
33
+ """
34
+ close_func: Callable[[], Any]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: datacom-device-api
3
- Version: 0.1.5
3
+ Version: 0.1.6
4
4
  Summary: Add your description here
5
5
  Requires-Python: >=3.14
6
6
  Description-Content-Type: text/markdown
@@ -8,6 +8,9 @@ src/datacom_device_api.egg-info/requires.txt
8
8
  src/datacom_device_api.egg-info/top_level.txt
9
9
  src/datacom_device_api/data/__init__.py
10
10
  src/datacom_device_api/data/table.py
11
+ src/datacom_device_api/event/event.py
12
+ src/datacom_device_api/ext/ext_meta.py
13
+ src/datacom_device_api/ext/ext_meta_display.py
11
14
  src/datacom_device_api/operation/__init__.py
12
15
  src/datacom_device_api/operation/table_operation.py
13
16
  src/datacom_device_api/operation/table_read_from_xlsx.py