chromedeveloperprotocol-client 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.
- cdp/__init__.py +4 -0
- cdp/domains.py +582 -0
- cdp/generator/__init__.py +3 -0
- cdp/generator/client_generator.py +246 -0
- cdp/generator/constant.py +4 -0
- cdp/generator/domain_generator.py +149 -0
- cdp/generator/event_generator.py +202 -0
- cdp/generator/method_generator.py +215 -0
- cdp/generator/service.py +153 -0
- cdp/generator/type_generator.py +231 -0
- cdp/protocol/__init__.py +0 -0
- cdp/protocol/accessibility/__init__.py +0 -0
- cdp/protocol/accessibility/events/__init__.py +0 -0
- cdp/protocol/accessibility/events/service.py +37 -0
- cdp/protocol/accessibility/events/types.py +14 -0
- cdp/protocol/accessibility/methods/__init__.py +0 -0
- cdp/protocol/accessibility/methods/service.py +109 -0
- cdp/protocol/accessibility/methods/types.py +70 -0
- cdp/protocol/accessibility/service.py +21 -0
- cdp/protocol/accessibility/types.py +89 -0
- cdp/protocol/animation/__init__.py +0 -0
- cdp/protocol/animation/events/__init__.py +0 -0
- cdp/protocol/animation/events/service.py +53 -0
- cdp/protocol/animation/events/types.py +20 -0
- cdp/protocol/animation/methods/__init__.py +0 -0
- cdp/protocol/animation/methods/service.py +131 -0
- cdp/protocol/animation/methods/types.py +52 -0
- cdp/protocol/animation/service.py +21 -0
- cdp/protocol/animation/types.py +79 -0
- cdp/protocol/audits/__init__.py +0 -0
- cdp/protocol/audits/events/__init__.py +0 -0
- cdp/protocol/audits/events/service.py +29 -0
- cdp/protocol/audits/events/types.py +10 -0
- cdp/protocol/audits/methods/__init__.py +0 -0
- cdp/protocol/audits/methods/service.py +76 -0
- cdp/protocol/audits/methods/types.py +36 -0
- cdp/protocol/audits/service.py +21 -0
- cdp/protocol/audits/types.py +293 -0
- cdp/protocol/autofill/__init__.py +0 -0
- cdp/protocol/autofill/events/__init__.py +0 -0
- cdp/protocol/autofill/events/service.py +29 -0
- cdp/protocol/autofill/events/types.py +14 -0
- cdp/protocol/autofill/methods/__init__.py +0 -0
- cdp/protocol/autofill/methods/service.py +65 -0
- cdp/protocol/autofill/methods/types.py +22 -0
- cdp/protocol/autofill/service.py +21 -0
- cdp/protocol/autofill/types.py +54 -0
- cdp/protocol/background_service/__init__.py +0 -0
- cdp/protocol/background_service/events/__init__.py +0 -0
- cdp/protocol/background_service/events/service.py +37 -0
- cdp/protocol/background_service/events/types.py +14 -0
- cdp/protocol/background_service/methods/__init__.py +0 -0
- cdp/protocol/background_service/methods/service.py +65 -0
- cdp/protocol/background_service/methods/types.py +17 -0
- cdp/protocol/background_service/service.py +21 -0
- cdp/protocol/background_service/types.py +32 -0
- cdp/protocol/bluetooth_emulation/__init__.py +0 -0
- cdp/protocol/bluetooth_emulation/events/__init__.py +0 -0
- cdp/protocol/bluetooth_emulation/events/service.py +45 -0
- cdp/protocol/bluetooth_emulation/events/types.py +23 -0
- cdp/protocol/bluetooth_emulation/methods/__init__.py +0 -0
- cdp/protocol/bluetooth_emulation/methods/service.py +186 -0
- cdp/protocol/bluetooth_emulation/methods/types.py +81 -0
- cdp/protocol/bluetooth_emulation/service.py +21 -0
- cdp/protocol/bluetooth_emulation/types.py +45 -0
- cdp/protocol/browser/__init__.py +0 -0
- cdp/protocol/browser/events/__init__.py +0 -0
- cdp/protocol/browser/events/service.py +37 -0
- cdp/protocol/browser/events/types.py +28 -0
- cdp/protocol/browser/methods/__init__.py +0 -0
- cdp/protocol/browser/methods/service.py +230 -0
- cdp/protocol/browser/methods/types.py +126 -0
- cdp/protocol/browser/service.py +21 -0
- cdp/protocol/browser/types.py +57 -0
- cdp/protocol/cache_storage/__init__.py +0 -0
- cdp/protocol/cache_storage/events/__init__.py +0 -0
- cdp/protocol/cache_storage/events/service.py +20 -0
- cdp/protocol/cache_storage/events/types.py +3 -0
- cdp/protocol/cache_storage/methods/__init__.py +0 -0
- cdp/protocol/cache_storage/methods/service.py +76 -0
- cdp/protocol/cache_storage/methods/types.py +57 -0
- cdp/protocol/cache_storage/service.py +21 -0
- cdp/protocol/cache_storage/types.py +49 -0
- cdp/protocol/cast/__init__.py +0 -0
- cdp/protocol/cast/events/__init__.py +0 -0
- cdp/protocol/cast/events/service.py +37 -0
- cdp/protocol/cast/events/types.py +12 -0
- cdp/protocol/cast/methods/__init__.py +0 -0
- cdp/protocol/cast/methods/service.py +87 -0
- cdp/protocol/cast/methods/types.py +15 -0
- cdp/protocol/cast/service.py +21 -0
- cdp/protocol/cast/types.py +9 -0
- cdp/protocol/css/__init__.py +0 -0
- cdp/protocol/css/events/__init__.py +0 -0
- cdp/protocol/css/events/service.py +69 -0
- cdp/protocol/css/events/types.py +27 -0
- cdp/protocol/css/methods/__init__.py +0 -0
- cdp/protocol/css/methods/service.py +428 -0
- cdp/protocol/css/methods/types.py +278 -0
- cdp/protocol/css/service.py +21 -0
- cdp/protocol/css/types.py +451 -0
- cdp/protocol/debugger/__init__.py +0 -0
- cdp/protocol/debugger/events/__init__.py +0 -0
- cdp/protocol/debugger/events/service.py +53 -0
- cdp/protocol/debugger/events/types.py +112 -0
- cdp/protocol/debugger/methods/__init__.py +0 -0
- cdp/protocol/debugger/methods/service.py +362 -0
- cdp/protocol/debugger/methods/types.py +250 -0
- cdp/protocol/debugger/service.py +21 -0
- cdp/protocol/debugger/types.py +91 -0
- cdp/protocol/device_access/__init__.py +0 -0
- cdp/protocol/device_access/events/__init__.py +0 -0
- cdp/protocol/device_access/events/service.py +29 -0
- cdp/protocol/device_access/events/types.py +12 -0
- cdp/protocol/device_access/methods/__init__.py +0 -0
- cdp/protocol/device_access/methods/service.py +65 -0
- cdp/protocol/device_access/methods/types.py +16 -0
- cdp/protocol/device_access/service.py +21 -0
- cdp/protocol/device_access/types.py +13 -0
- cdp/protocol/device_orientation/__init__.py +0 -0
- cdp/protocol/device_orientation/events/__init__.py +0 -0
- cdp/protocol/device_orientation/events/service.py +20 -0
- cdp/protocol/device_orientation/events/types.py +3 -0
- cdp/protocol/device_orientation/methods/__init__.py +0 -0
- cdp/protocol/device_orientation/methods/service.py +43 -0
- cdp/protocol/device_orientation/methods/types.py +12 -0
- cdp/protocol/device_orientation/service.py +21 -0
- cdp/protocol/device_orientation/types.py +3 -0
- cdp/protocol/dom/__init__.py +0 -0
- cdp/protocol/dom/events/__init__.py +0 -0
- cdp/protocol/dom/events/service.py +165 -0
- cdp/protocol/dom/events/types.py +97 -0
- cdp/protocol/dom/methods/__init__.py +0 -0
- cdp/protocol/dom/methods/service.py +593 -0
- cdp/protocol/dom/methods/types.py +384 -0
- cdp/protocol/dom/service.py +21 -0
- cdp/protocol/dom/types.py +151 -0
- cdp/protocol/dom_debugger/__init__.py +0 -0
- cdp/protocol/dom_debugger/events/__init__.py +0 -0
- cdp/protocol/dom_debugger/events/service.py +20 -0
- cdp/protocol/dom_debugger/events/types.py +3 -0
- cdp/protocol/dom_debugger/methods/__init__.py +0 -0
- cdp/protocol/dom_debugger/methods/service.py +109 -0
- cdp/protocol/dom_debugger/methods/types.py +51 -0
- cdp/protocol/dom_debugger/service.py +21 -0
- cdp/protocol/dom_debugger/types.py +36 -0
- cdp/protocol/dom_snapshot/__init__.py +0 -0
- cdp/protocol/dom_snapshot/events/__init__.py +0 -0
- cdp/protocol/dom_snapshot/events/service.py +20 -0
- cdp/protocol/dom_snapshot/events/types.py +3 -0
- cdp/protocol/dom_snapshot/methods/__init__.py +0 -0
- cdp/protocol/dom_snapshot/methods/service.py +54 -0
- cdp/protocol/dom_snapshot/methods/types.py +28 -0
- cdp/protocol/dom_snapshot/service.py +21 -0
- cdp/protocol/dom_snapshot/types.py +220 -0
- cdp/protocol/dom_storage/__init__.py +0 -0
- cdp/protocol/dom_storage/events/__init__.py +0 -0
- cdp/protocol/dom_storage/events/service.py +53 -0
- cdp/protocol/dom_storage/events/types.py +22 -0
- cdp/protocol/dom_storage/methods/__init__.py +0 -0
- cdp/protocol/dom_storage/methods/service.py +87 -0
- cdp/protocol/dom_storage/methods/types.py +27 -0
- cdp/protocol/dom_storage/service.py +21 -0
- cdp/protocol/dom_storage/types.py +15 -0
- cdp/protocol/emulation/__init__.py +0 -0
- cdp/protocol/emulation/events/__init__.py +0 -0
- cdp/protocol/emulation/events/service.py +29 -0
- cdp/protocol/emulation/events/types.py +6 -0
- cdp/protocol/emulation/methods/__init__.py +0 -0
- cdp/protocol/emulation/methods/service.py +494 -0
- cdp/protocol/emulation/methods/types.py +261 -0
- cdp/protocol/emulation/service.py +21 -0
- cdp/protocol/emulation/types.py +132 -0
- cdp/protocol/event_breakpoints/__init__.py +0 -0
- cdp/protocol/event_breakpoints/events/__init__.py +0 -0
- cdp/protocol/event_breakpoints/events/service.py +20 -0
- cdp/protocol/event_breakpoints/events/types.py +3 -0
- cdp/protocol/event_breakpoints/methods/__init__.py +0 -0
- cdp/protocol/event_breakpoints/methods/service.py +54 -0
- cdp/protocol/event_breakpoints/methods/types.py +10 -0
- cdp/protocol/event_breakpoints/service.py +21 -0
- cdp/protocol/event_breakpoints/types.py +3 -0
- cdp/protocol/extensions/__init__.py +0 -0
- cdp/protocol/extensions/events/__init__.py +0 -0
- cdp/protocol/extensions/events/service.py +20 -0
- cdp/protocol/extensions/events/types.py +3 -0
- cdp/protocol/extensions/methods/__init__.py +0 -0
- cdp/protocol/extensions/methods/service.py +87 -0
- cdp/protocol/extensions/methods/types.py +46 -0
- cdp/protocol/extensions/service.py +21 -0
- cdp/protocol/extensions/types.py +6 -0
- cdp/protocol/fed_cm/__init__.py +0 -0
- cdp/protocol/fed_cm/events/__init__.py +0 -0
- cdp/protocol/fed_cm/events/service.py +37 -0
- cdp/protocol/fed_cm/events/types.py +18 -0
- cdp/protocol/fed_cm/methods/__init__.py +0 -0
- cdp/protocol/fed_cm/methods/service.py +98 -0
- cdp/protocol/fed_cm/methods/types.py +26 -0
- cdp/protocol/fed_cm/service.py +21 -0
- cdp/protocol/fed_cm/types.py +25 -0
- cdp/protocol/fetch/__init__.py +0 -0
- cdp/protocol/fetch/events/__init__.py +0 -0
- cdp/protocol/fetch/events/service.py +37 -0
- cdp/protocol/fetch/events/types.py +47 -0
- cdp/protocol/fetch/methods/__init__.py +0 -0
- cdp/protocol/fetch/methods/service.py +120 -0
- cdp/protocol/fetch/methods/types.py +85 -0
- cdp/protocol/fetch/service.py +21 -0
- cdp/protocol/fetch/types.py +41 -0
- cdp/protocol/file_system/__init__.py +0 -0
- cdp/protocol/file_system/events/__init__.py +0 -0
- cdp/protocol/file_system/events/service.py +20 -0
- cdp/protocol/file_system/events/types.py +3 -0
- cdp/protocol/file_system/methods/__init__.py +0 -0
- cdp/protocol/file_system/methods/service.py +32 -0
- cdp/protocol/file_system/methods/types.py +14 -0
- cdp/protocol/file_system/service.py +21 -0
- cdp/protocol/file_system/types.py +28 -0
- cdp/protocol/headless_experimental/__init__.py +0 -0
- cdp/protocol/headless_experimental/events/__init__.py +0 -0
- cdp/protocol/headless_experimental/events/service.py +20 -0
- cdp/protocol/headless_experimental/events/types.py +3 -0
- cdp/protocol/headless_experimental/methods/__init__.py +0 -0
- cdp/protocol/headless_experimental/methods/service.py +32 -0
- cdp/protocol/headless_experimental/methods/types.py +22 -0
- cdp/protocol/headless_experimental/service.py +21 -0
- cdp/protocol/headless_experimental/types.py +12 -0
- cdp/protocol/heap_profiler/__init__.py +0 -0
- cdp/protocol/heap_profiler/events/__init__.py +0 -0
- cdp/protocol/heap_profiler/events/service.py +61 -0
- cdp/protocol/heap_profiler/events/types.py +18 -0
- cdp/protocol/heap_profiler/methods/__init__.py +0 -0
- cdp/protocol/heap_profiler/methods/service.py +153 -0
- cdp/protocol/heap_profiler/methods/types.py +73 -0
- cdp/protocol/heap_profiler/service.py +21 -0
- cdp/protocol/heap_profiler/types.py +32 -0
- cdp/protocol/indexed_db/__init__.py +0 -0
- cdp/protocol/indexed_db/events/__init__.py +0 -0
- cdp/protocol/indexed_db/events/service.py +20 -0
- cdp/protocol/indexed_db/events/types.py +3 -0
- cdp/protocol/indexed_db/methods/__init__.py +0 -0
- cdp/protocol/indexed_db/methods/service.py +120 -0
- cdp/protocol/indexed_db/methods/types.py +111 -0
- cdp/protocol/indexed_db/service.py +21 -0
- cdp/protocol/indexed_db/types.py +74 -0
- cdp/protocol/input/__init__.py +0 -0
- cdp/protocol/input/events/__init__.py +0 -0
- cdp/protocol/input/events/service.py +29 -0
- cdp/protocol/input/events/types.py +10 -0
- cdp/protocol/input/methods/__init__.py +0 -0
- cdp/protocol/input/methods/service.py +164 -0
- cdp/protocol/input/methods/types.py +181 -0
- cdp/protocol/input/service.py +21 -0
- cdp/protocol/input/types.py +46 -0
- cdp/protocol/inspector/__init__.py +0 -0
- cdp/protocol/inspector/events/__init__.py +0 -0
- cdp/protocol/inspector/events/service.py +53 -0
- cdp/protocol/inspector/events/types.py +13 -0
- cdp/protocol/inspector/methods/__init__.py +0 -0
- cdp/protocol/inspector/methods/service.py +43 -0
- cdp/protocol/inspector/methods/types.py +3 -0
- cdp/protocol/inspector/service.py +21 -0
- cdp/protocol/inspector/types.py +3 -0
- cdp/protocol/io/__init__.py +0 -0
- cdp/protocol/io/events/__init__.py +0 -0
- cdp/protocol/io/events/service.py +20 -0
- cdp/protocol/io/events/types.py +3 -0
- cdp/protocol/io/methods/__init__.py +0 -0
- cdp/protocol/io/methods/service.py +54 -0
- cdp/protocol/io/methods/types.py +33 -0
- cdp/protocol/io/service.py +21 -0
- cdp/protocol/io/types.py +6 -0
- cdp/protocol/layer_tree/__init__.py +0 -0
- cdp/protocol/layer_tree/events/__init__.py +0 -0
- cdp/protocol/layer_tree/events/service.py +37 -0
- cdp/protocol/layer_tree/events/types.py +18 -0
- cdp/protocol/layer_tree/methods/__init__.py +0 -0
- cdp/protocol/layer_tree/methods/service.py +120 -0
- cdp/protocol/layer_tree/methods/types.py +70 -0
- cdp/protocol/layer_tree/service.py +21 -0
- cdp/protocol/layer_tree/types.py +73 -0
- cdp/protocol/log/__init__.py +0 -0
- cdp/protocol/log/events/__init__.py +0 -0
- cdp/protocol/log/events/service.py +29 -0
- cdp/protocol/log/events/types.py +11 -0
- cdp/protocol/log/methods/__init__.py +0 -0
- cdp/protocol/log/methods/service.py +76 -0
- cdp/protocol/log/methods/types.py +14 -0
- cdp/protocol/log/service.py +21 -0
- cdp/protocol/log/types.py +40 -0
- cdp/protocol/media/__init__.py +0 -0
- cdp/protocol/media/events/__init__.py +0 -0
- cdp/protocol/media/events/service.py +61 -0
- cdp/protocol/media/events/types.py +27 -0
- cdp/protocol/media/methods/__init__.py +0 -0
- cdp/protocol/media/methods/service.py +43 -0
- cdp/protocol/media/methods/types.py +3 -0
- cdp/protocol/media/service.py +21 -0
- cdp/protocol/media/types.py +42 -0
- cdp/protocol/memory/__init__.py +0 -0
- cdp/protocol/memory/events/__init__.py +0 -0
- cdp/protocol/memory/events/service.py +20 -0
- cdp/protocol/memory/events/types.py +3 -0
- cdp/protocol/memory/methods/__init__.py +0 -0
- cdp/protocol/memory/methods/service.py +142 -0
- cdp/protocol/memory/methods/types.py +48 -0
- cdp/protocol/memory/service.py +21 -0
- cdp/protocol/memory/types.py +34 -0
- cdp/protocol/network/__init__.py +0 -0
- cdp/protocol/network/events/__init__.py +0 -0
- cdp/protocol/network/events/service.py +365 -0
- cdp/protocol/network/events/types.py +360 -0
- cdp/protocol/network/methods/__init__.py +0 -0
- cdp/protocol/network/methods/service.py +384 -0
- cdp/protocol/network/methods/types.py +252 -0
- cdp/protocol/network/service.py +21 -0
- cdp/protocol/network/types.py +691 -0
- cdp/protocol/overlay/__init__.py +0 -0
- cdp/protocol/overlay/events/__init__.py +0 -0
- cdp/protocol/overlay/events/service.py +53 -0
- cdp/protocol/overlay/events/types.py +20 -0
- cdp/protocol/overlay/methods/__init__.py +0 -0
- cdp/protocol/overlay/methods/service.py +307 -0
- cdp/protocol/overlay/methods/types.py +144 -0
- cdp/protocol/overlay/service.py +21 -0
- cdp/protocol/overlay/types.py +198 -0
- cdp/protocol/page/__init__.py +0 -0
- cdp/protocol/page/events/__init__.py +0 -0
- cdp/protocol/page/events/service.py +213 -0
- cdp/protocol/page/events/types.py +147 -0
- cdp/protocol/page/methods/__init__.py +0 -0
- cdp/protocol/page/methods/service.py +560 -0
- cdp/protocol/page/methods/types.py +346 -0
- cdp/protocol/page/service.py +21 -0
- cdp/protocol/page/types.py +379 -0
- cdp/protocol/performance/__init__.py +0 -0
- cdp/protocol/performance/events/__init__.py +0 -0
- cdp/protocol/performance/events/service.py +29 -0
- cdp/protocol/performance/events/types.py +13 -0
- cdp/protocol/performance/methods/__init__.py +0 -0
- cdp/protocol/performance/methods/service.py +54 -0
- cdp/protocol/performance/methods/types.py +18 -0
- cdp/protocol/performance/service.py +21 -0
- cdp/protocol/performance/types.py +10 -0
- cdp/protocol/performance_timeline/__init__.py +0 -0
- cdp/protocol/performance_timeline/events/__init__.py +0 -0
- cdp/protocol/performance_timeline/events/service.py +29 -0
- cdp/protocol/performance_timeline/events/types.py +10 -0
- cdp/protocol/performance_timeline/methods/__init__.py +0 -0
- cdp/protocol/performance_timeline/methods/service.py +32 -0
- cdp/protocol/performance_timeline/methods/types.py +7 -0
- cdp/protocol/performance_timeline/service.py +21 -0
- cdp/protocol/performance_timeline/types.py +46 -0
- cdp/protocol/preload/__init__.py +0 -0
- cdp/protocol/preload/events/__init__.py +0 -0
- cdp/protocol/preload/events/service.py +69 -0
- cdp/protocol/preload/events/types.py +49 -0
- cdp/protocol/preload/methods/__init__.py +0 -0
- cdp/protocol/preload/methods/service.py +43 -0
- cdp/protocol/preload/methods/types.py +3 -0
- cdp/protocol/preload/service.py +21 -0
- cdp/protocol/preload/types.py +56 -0
- cdp/protocol/profiler/__init__.py +0 -0
- cdp/protocol/profiler/events/__init__.py +0 -0
- cdp/protocol/profiler/events/service.py +45 -0
- cdp/protocol/profiler/events/types.py +30 -0
- cdp/protocol/profiler/methods/__init__.py +0 -0
- cdp/protocol/profiler/methods/service.py +120 -0
- cdp/protocol/profiler/methods/types.py +45 -0
- cdp/protocol/profiler/service.py +21 -0
- cdp/protocol/profiler/types.py +65 -0
- cdp/protocol/pwa/__init__.py +0 -0
- cdp/protocol/pwa/events/__init__.py +0 -0
- cdp/protocol/pwa/events/service.py +20 -0
- cdp/protocol/pwa/events/types.py +3 -0
- cdp/protocol/pwa/methods/__init__.py +0 -0
- cdp/protocol/pwa/methods/service.py +98 -0
- cdp/protocol/pwa/methods/types.py +43 -0
- cdp/protocol/pwa/service.py +21 -0
- cdp/protocol/pwa/types.py +15 -0
- cdp/protocol/py.typed +0 -0
- cdp/protocol/runtime/__init__.py +0 -0
- cdp/protocol/runtime/events/__init__.py +0 -0
- cdp/protocol/runtime/events/service.py +85 -0
- cdp/protocol/runtime/events/types.py +55 -0
- cdp/protocol/runtime/methods/__init__.py +0 -0
- cdp/protocol/runtime/methods/service.py +274 -0
- cdp/protocol/runtime/methods/types.py +226 -0
- cdp/protocol/runtime/service.py +21 -0
- cdp/protocol/runtime/types.py +194 -0
- cdp/protocol/security/__init__.py +0 -0
- cdp/protocol/security/events/__init__.py +0 -0
- cdp/protocol/security/events/service.py +29 -0
- cdp/protocol/security/events/types.py +11 -0
- cdp/protocol/security/methods/__init__.py +0 -0
- cdp/protocol/security/methods/service.py +54 -0
- cdp/protocol/security/methods/types.py +9 -0
- cdp/protocol/security/service.py +21 -0
- cdp/protocol/security/types.py +102 -0
- cdp/protocol/service_worker/__init__.py +0 -0
- cdp/protocol/service_worker/events/__init__.py +0 -0
- cdp/protocol/service_worker/events/service.py +45 -0
- cdp/protocol/service_worker/events/types.py +16 -0
- cdp/protocol/service_worker/methods/__init__.py +0 -0
- cdp/protocol/service_worker/methods/service.py +153 -0
- cdp/protocol/service_worker/methods/types.py +36 -0
- cdp/protocol/service_worker/service.py +21 -0
- cdp/protocol/service_worker/types.py +38 -0
- cdp/protocol/storage/__init__.py +0 -0
- cdp/protocol/storage/events/__init__.py +0 -0
- cdp/protocol/storage/events/service.py +141 -0
- cdp/protocol/storage/events/types.py +139 -0
- cdp/protocol/storage/methods/__init__.py +0 -0
- cdp/protocol/storage/methods/service.py +428 -0
- cdp/protocol/storage/methods/types.py +184 -0
- cdp/protocol/storage/service.py +21 -0
- cdp/protocol/storage/types.py +236 -0
- cdp/protocol/system_info/__init__.py +0 -0
- cdp/protocol/system_info/events/__init__.py +0 -0
- cdp/protocol/system_info/events/service.py +20 -0
- cdp/protocol/system_info/events/types.py +3 -0
- cdp/protocol/system_info/methods/__init__.py +0 -0
- cdp/protocol/system_info/methods/service.py +54 -0
- cdp/protocol/system_info/methods/types.py +27 -0
- cdp/protocol/system_info/service.py +21 -0
- cdp/protocol/system_info/types.py +71 -0
- cdp/protocol/target/__init__.py +0 -0
- cdp/protocol/target/events/__init__.py +0 -0
- cdp/protocol/target/events/service.py +77 -0
- cdp/protocol/target/events/types.py +38 -0
- cdp/protocol/target/methods/__init__.py +0 -0
- cdp/protocol/target/methods/service.py +219 -0
- cdp/protocol/target/methods/types.py +148 -0
- cdp/protocol/target/service.py +21 -0
- cdp/protocol/target/types.py +44 -0
- cdp/protocol/tethering/__init__.py +0 -0
- cdp/protocol/tethering/events/__init__.py +0 -0
- cdp/protocol/tethering/events/service.py +29 -0
- cdp/protocol/tethering/events/types.py +9 -0
- cdp/protocol/tethering/methods/__init__.py +0 -0
- cdp/protocol/tethering/methods/service.py +43 -0
- cdp/protocol/tethering/methods/types.py +10 -0
- cdp/protocol/tethering/service.py +21 -0
- cdp/protocol/tethering/types.py +3 -0
- cdp/protocol/tracing/__init__.py +0 -0
- cdp/protocol/tracing/events/__init__.py +0 -0
- cdp/protocol/tracing/events/service.py +45 -0
- cdp/protocol/tracing/events/types.py +28 -0
- cdp/protocol/tracing/methods/__init__.py +0 -0
- cdp/protocol/tracing/methods/service.py +87 -0
- cdp/protocol/tracing/methods/types.py +54 -0
- cdp/protocol/tracing/service.py +21 -0
- cdp/protocol/tracing/types.py +34 -0
- cdp/protocol/web_audio/__init__.py +0 -0
- cdp/protocol/web_audio/events/__init__.py +0 -0
- cdp/protocol/web_audio/events/service.py +125 -0
- cdp/protocol/web_audio/events/types.py +56 -0
- cdp/protocol/web_audio/methods/__init__.py +0 -0
- cdp/protocol/web_audio/methods/service.py +54 -0
- cdp/protocol/web_audio/methods/types.py +17 -0
- cdp/protocol/web_audio/service.py +21 -0
- cdp/protocol/web_audio/types.py +66 -0
- cdp/protocol/web_authn/__init__.py +0 -0
- cdp/protocol/web_authn/events/__init__.py +0 -0
- cdp/protocol/web_authn/events/service.py +53 -0
- cdp/protocol/web_authn/events/types.py +21 -0
- cdp/protocol/web_authn/methods/__init__.py +0 -0
- cdp/protocol/web_authn/methods/service.py +164 -0
- cdp/protocol/web_authn/methods/types.py +61 -0
- cdp/protocol/web_authn/service.py +21 -0
- cdp/protocol/web_authn/types.py +54 -0
- cdp/py.typed +0 -0
- cdp/service.py +184 -0
- chromedeveloperprotocol_client-0.1.0.dist-info/METADATA +15 -0
- chromedeveloperprotocol_client-0.1.0.dist-info/RECORD +476 -0
- chromedeveloperprotocol_client-0.1.0.dist-info/WHEEL +4 -0
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
"""CDP Tracing Domain Methods"""
|
|
2
|
+
from ..types import *
|
|
3
|
+
from .types import *
|
|
4
|
+
from typing import Optional, Dict, Any, Callable, TYPE_CHECKING
|
|
5
|
+
|
|
6
|
+
if TYPE_CHECKING:
|
|
7
|
+
from ....service import Client
|
|
8
|
+
|
|
9
|
+
class TracingMethods:
|
|
10
|
+
"""
|
|
11
|
+
Methods for the Tracing domain.
|
|
12
|
+
"""
|
|
13
|
+
def __init__(self, client: "Client"):
|
|
14
|
+
"""
|
|
15
|
+
Initialize the Tracing methods.
|
|
16
|
+
|
|
17
|
+
Args:
|
|
18
|
+
client ("Client"): The parent CDP client instance.
|
|
19
|
+
"""
|
|
20
|
+
self.client = client
|
|
21
|
+
|
|
22
|
+
async def end(self, params: None=None,session_id: Optional[str] = None) -> Dict[str, Any]:
|
|
23
|
+
"""
|
|
24
|
+
Stop trace events collection.
|
|
25
|
+
Args:
|
|
26
|
+
params (None, optional): Parameters for the end method.
|
|
27
|
+
session_id (str, optional): Target session ID for flat protocol usage.
|
|
28
|
+
|
|
29
|
+
Returns:
|
|
30
|
+
Dict[str, Any]: The result of the end call.
|
|
31
|
+
"""
|
|
32
|
+
return await self.client.send(method="Tracing.end", params=params,session_id=session_id)
|
|
33
|
+
async def get_categories(self, params: None=None,session_id: Optional[str] = None) -> getCategoriesReturns:
|
|
34
|
+
"""
|
|
35
|
+
Gets supported tracing categories.
|
|
36
|
+
Args:
|
|
37
|
+
params (None, optional): Parameters for the getCategories method.
|
|
38
|
+
session_id (str, optional): Target session ID for flat protocol usage.
|
|
39
|
+
|
|
40
|
+
Returns:
|
|
41
|
+
getCategoriesReturns: The result of the getCategories call.
|
|
42
|
+
"""
|
|
43
|
+
return await self.client.send(method="Tracing.getCategories", params=params,session_id=session_id)
|
|
44
|
+
async def get_track_event_descriptor(self, params: None=None,session_id: Optional[str] = None) -> getTrackEventDescriptorReturns:
|
|
45
|
+
"""
|
|
46
|
+
Return a descriptor for all available tracing categories.
|
|
47
|
+
Args:
|
|
48
|
+
params (None, optional): Parameters for the getTrackEventDescriptor method.
|
|
49
|
+
session_id (str, optional): Target session ID for flat protocol usage.
|
|
50
|
+
|
|
51
|
+
Returns:
|
|
52
|
+
getTrackEventDescriptorReturns: The result of the getTrackEventDescriptor call.
|
|
53
|
+
"""
|
|
54
|
+
return await self.client.send(method="Tracing.getTrackEventDescriptor", params=params,session_id=session_id)
|
|
55
|
+
async def record_clock_sync_marker(self, params: Optional[recordClockSyncMarkerParameters]=None,session_id: Optional[str] = None) -> Dict[str, Any]:
|
|
56
|
+
"""
|
|
57
|
+
Record a clock sync marker in the trace.
|
|
58
|
+
Args:
|
|
59
|
+
params (recordClockSyncMarkerParameters, optional): Parameters for the recordClockSyncMarker method.
|
|
60
|
+
session_id (str, optional): Target session ID for flat protocol usage.
|
|
61
|
+
|
|
62
|
+
Returns:
|
|
63
|
+
Dict[str, Any]: The result of the recordClockSyncMarker call.
|
|
64
|
+
"""
|
|
65
|
+
return await self.client.send(method="Tracing.recordClockSyncMarker", params=params,session_id=session_id)
|
|
66
|
+
async def request_memory_dump(self, params: Optional[requestMemoryDumpParameters]=None,session_id: Optional[str] = None) -> requestMemoryDumpReturns:
|
|
67
|
+
"""
|
|
68
|
+
Request a global memory dump.
|
|
69
|
+
Args:
|
|
70
|
+
params (requestMemoryDumpParameters, optional): Parameters for the requestMemoryDump method.
|
|
71
|
+
session_id (str, optional): Target session ID for flat protocol usage.
|
|
72
|
+
|
|
73
|
+
Returns:
|
|
74
|
+
requestMemoryDumpReturns: The result of the requestMemoryDump call.
|
|
75
|
+
"""
|
|
76
|
+
return await self.client.send(method="Tracing.requestMemoryDump", params=params,session_id=session_id)
|
|
77
|
+
async def start(self, params: Optional[startParameters]=None,session_id: Optional[str] = None) -> Dict[str, Any]:
|
|
78
|
+
"""
|
|
79
|
+
Start trace events collection.
|
|
80
|
+
Args:
|
|
81
|
+
params (startParameters, optional): Parameters for the start method.
|
|
82
|
+
session_id (str, optional): Target session ID for flat protocol usage.
|
|
83
|
+
|
|
84
|
+
Returns:
|
|
85
|
+
Dict[str, Any]: The result of the start call.
|
|
86
|
+
"""
|
|
87
|
+
return await self.client.send(method="Tracing.start", params=params,session_id=session_id)
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"""CDP Tracing Methods Types"""
|
|
2
|
+
|
|
3
|
+
from typing import TypedDict, NotRequired, Required, Literal, Any, Dict, Union, Optional, List, Set, Tuple
|
|
4
|
+
|
|
5
|
+
from typing import TYPE_CHECKING
|
|
6
|
+
if TYPE_CHECKING:
|
|
7
|
+
from cdp.protocol.tracing.types import MemoryDumpLevelOfDetail
|
|
8
|
+
from cdp.protocol.tracing.types import StreamCompression
|
|
9
|
+
from cdp.protocol.tracing.types import StreamFormat
|
|
10
|
+
from cdp.protocol.tracing.types import TraceConfig
|
|
11
|
+
from cdp.protocol.tracing.types import TracingBackend
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
class recordClockSyncMarkerParameters(TypedDict, total=True):
|
|
17
|
+
syncId: 'str'
|
|
18
|
+
"""The ID of this clock sync marker"""
|
|
19
|
+
class requestMemoryDumpParameters(TypedDict, total=False):
|
|
20
|
+
deterministic: NotRequired['bool']
|
|
21
|
+
"""Enables more deterministic results by forcing garbage collection"""
|
|
22
|
+
levelOfDetail: NotRequired['MemoryDumpLevelOfDetail']
|
|
23
|
+
"""Specifies level of details in memory dump. Defaults to "detailed"."""
|
|
24
|
+
class startParameters(TypedDict, total=False):
|
|
25
|
+
categories: NotRequired['str']
|
|
26
|
+
"""Category/tag filter"""
|
|
27
|
+
options: NotRequired['str']
|
|
28
|
+
"""Tracing options"""
|
|
29
|
+
bufferUsageReportingInterval: NotRequired['float']
|
|
30
|
+
"""If set, the agent will issue bufferUsage events at this interval, specified in milliseconds"""
|
|
31
|
+
transferMode: NotRequired['Literal["ReportEvents", "ReturnAsStream"]']
|
|
32
|
+
"""Whether to report trace events as series of dataCollected events or to save trace to a stream (defaults to ReportEvents)."""
|
|
33
|
+
streamFormat: NotRequired['StreamFormat']
|
|
34
|
+
"""Trace data format to use. This only applies when using ReturnAsStream transfer mode (defaults to json)."""
|
|
35
|
+
streamCompression: NotRequired['StreamCompression']
|
|
36
|
+
"""Compression format to use. This only applies when using ReturnAsStream transfer mode (defaults to none)"""
|
|
37
|
+
traceConfig: NotRequired['TraceConfig']
|
|
38
|
+
perfettoConfig: NotRequired['str']
|
|
39
|
+
"""Base64-encoded serialized perfetto.protos.TraceConfig protobuf message When specified, the parameters categories, options, traceConfig are ignored. (Encoded as a base64 string when passed over JSON)"""
|
|
40
|
+
tracingBackend: NotRequired['TracingBackend']
|
|
41
|
+
"""Backend type (defaults to auto)"""
|
|
42
|
+
|
|
43
|
+
class getCategoriesReturns(TypedDict):
|
|
44
|
+
categories: 'List[str]'
|
|
45
|
+
"""A list of supported tracing categories."""
|
|
46
|
+
class getTrackEventDescriptorReturns(TypedDict):
|
|
47
|
+
descriptor: 'str'
|
|
48
|
+
"""Base64-encoded serialized perfetto.protos.TrackEventDescriptor protobuf message. (Encoded as a base64 string when passed over JSON)"""
|
|
49
|
+
|
|
50
|
+
class requestMemoryDumpReturns(TypedDict):
|
|
51
|
+
dumpGuid: 'str'
|
|
52
|
+
"""GUID of the resulting global memory dump."""
|
|
53
|
+
success: 'bool'
|
|
54
|
+
"""True iff the global memory dump succeeded."""
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"""CDP Tracing Domain"""
|
|
2
|
+
from typing import TYPE_CHECKING
|
|
3
|
+
from .methods.service import TracingMethods
|
|
4
|
+
from .events.service import TracingEvents
|
|
5
|
+
|
|
6
|
+
if TYPE_CHECKING:
|
|
7
|
+
from ...service import Client
|
|
8
|
+
|
|
9
|
+
class Tracing(TracingMethods, TracingEvents):
|
|
10
|
+
"""
|
|
11
|
+
Access the Tracing domain.
|
|
12
|
+
"""
|
|
13
|
+
def __init__(self, client: "Client"):
|
|
14
|
+
"""
|
|
15
|
+
Initialize the Tracing domain.
|
|
16
|
+
|
|
17
|
+
Args:
|
|
18
|
+
client ("Client"): The parent CDP client instance.
|
|
19
|
+
"""
|
|
20
|
+
TracingMethods.__init__(self, client)
|
|
21
|
+
TracingEvents.__init__(self, client)
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"""CDP Tracing Types"""
|
|
2
|
+
|
|
3
|
+
from typing import TypedDict, NotRequired, Required, Literal, Any, Dict, Union, Optional, List, Set, Tuple
|
|
4
|
+
|
|
5
|
+
class MemoryDumpConfig(TypedDict, total=True):
|
|
6
|
+
"""Configuration for memory dump. Used only when "memory-infra" category is enabled."""
|
|
7
|
+
pass
|
|
8
|
+
class TraceConfig(TypedDict, total=False):
|
|
9
|
+
recordMode: NotRequired['Literal["recordUntilFull", "recordContinuously", "recordAsMuchAsPossible", "echoToConsole"]']
|
|
10
|
+
"""Controls how the trace buffer stores data. The default is recordUntilFull."""
|
|
11
|
+
traceBufferSizeInKb: NotRequired['float']
|
|
12
|
+
"""Size of the trace buffer in kilobytes. If not specified or zero is passed, a default value of 200 MB would be used."""
|
|
13
|
+
enableSampling: NotRequired['bool']
|
|
14
|
+
"""Turns on JavaScript stack sampling."""
|
|
15
|
+
enableSystrace: NotRequired['bool']
|
|
16
|
+
"""Turns on system tracing."""
|
|
17
|
+
enableArgumentFilter: NotRequired['bool']
|
|
18
|
+
"""Turns on argument filter."""
|
|
19
|
+
includedCategories: NotRequired['List[str]']
|
|
20
|
+
"""Included category filters."""
|
|
21
|
+
excludedCategories: NotRequired['List[str]']
|
|
22
|
+
"""Excluded category filters."""
|
|
23
|
+
syntheticDelays: NotRequired['List[str]']
|
|
24
|
+
"""Configuration to synthesize the delays in tracing."""
|
|
25
|
+
memoryDumpConfig: NotRequired['MemoryDumpConfig']
|
|
26
|
+
"""Configuration for memory dump triggers. Used only when "memory-infra" category is enabled."""
|
|
27
|
+
StreamFormat = Literal['json','proto']
|
|
28
|
+
"""Data format of a trace. Can be either the legacy JSON format or the protocol buffer format. Note that the JSON format will be deprecated soon."""
|
|
29
|
+
StreamCompression = Literal['none','gzip']
|
|
30
|
+
"""Compression type to use for traces returned via streams."""
|
|
31
|
+
MemoryDumpLevelOfDetail = Literal['background','light','detailed']
|
|
32
|
+
"""Details exposed when memory request explicitly declared. Keep consistent with memory_dump_request_args.h and memory_instrumentation.mojom"""
|
|
33
|
+
TracingBackend = Literal['auto','chrome','system']
|
|
34
|
+
"""Backend type to use for tracing. `chrome` uses the Chrome-integrated tracing service and is supported on all platforms. `system` is only supported on Chrome OS and uses the Perfetto system tracing service. `auto` chooses `system` when the perfettoConfig provided to Tracing.start specifies at least one non-Chrome data source; otherwise uses `chrome`."""
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
"""CDP WebAudio Domain Events"""
|
|
2
|
+
from ..types import *
|
|
3
|
+
from .types import *
|
|
4
|
+
from typing import Optional, Dict, Any, Callable, TYPE_CHECKING
|
|
5
|
+
|
|
6
|
+
if TYPE_CHECKING:
|
|
7
|
+
from ....service import Client
|
|
8
|
+
|
|
9
|
+
class WebAudioEvents:
|
|
10
|
+
"""
|
|
11
|
+
Events for the WebAudio domain.
|
|
12
|
+
"""
|
|
13
|
+
def __init__(self, client: "Client"):
|
|
14
|
+
"""
|
|
15
|
+
Initialize the WebAudio events.
|
|
16
|
+
|
|
17
|
+
Args:
|
|
18
|
+
client ("Client"): The parent CDP client instance.
|
|
19
|
+
"""
|
|
20
|
+
self.client = client
|
|
21
|
+
|
|
22
|
+
def on_context_created(self, callback: Callable[[contextCreatedEvent,Optional[str]], None]=None) -> None:
|
|
23
|
+
"""
|
|
24
|
+
Notifies that a new BaseAudioContext has been created.
|
|
25
|
+
Args:
|
|
26
|
+
callback (callable, optional): Function called when the event is fired.
|
|
27
|
+
The callback receives (params: contextCreatedEvent, session_id: Optional[str]).
|
|
28
|
+
"""
|
|
29
|
+
self.client.on('WebAudio.contextCreated', callback)
|
|
30
|
+
def on_context_will_be_destroyed(self, callback: Callable[[contextWillBeDestroyedEvent,Optional[str]], None]=None) -> None:
|
|
31
|
+
"""
|
|
32
|
+
Notifies that an existing BaseAudioContext will be destroyed.
|
|
33
|
+
Args:
|
|
34
|
+
callback (callable, optional): Function called when the event is fired.
|
|
35
|
+
The callback receives (params: contextWillBeDestroyedEvent, session_id: Optional[str]).
|
|
36
|
+
"""
|
|
37
|
+
self.client.on('WebAudio.contextWillBeDestroyed', callback)
|
|
38
|
+
def on_context_changed(self, callback: Callable[[contextChangedEvent,Optional[str]], None]=None) -> None:
|
|
39
|
+
"""
|
|
40
|
+
Notifies that existing BaseAudioContext has changed some properties (id stays the same)..
|
|
41
|
+
Args:
|
|
42
|
+
callback (callable, optional): Function called when the event is fired.
|
|
43
|
+
The callback receives (params: contextChangedEvent, session_id: Optional[str]).
|
|
44
|
+
"""
|
|
45
|
+
self.client.on('WebAudio.contextChanged', callback)
|
|
46
|
+
def on_audio_listener_created(self, callback: Callable[[audioListenerCreatedEvent,Optional[str]], None]=None) -> None:
|
|
47
|
+
"""
|
|
48
|
+
Notifies that the construction of an AudioListener has finished.
|
|
49
|
+
Args:
|
|
50
|
+
callback (callable, optional): Function called when the event is fired.
|
|
51
|
+
The callback receives (params: audioListenerCreatedEvent, session_id: Optional[str]).
|
|
52
|
+
"""
|
|
53
|
+
self.client.on('WebAudio.audioListenerCreated', callback)
|
|
54
|
+
def on_audio_listener_will_be_destroyed(self, callback: Callable[[audioListenerWillBeDestroyedEvent,Optional[str]], None]=None) -> None:
|
|
55
|
+
"""
|
|
56
|
+
Notifies that a new AudioListener has been created.
|
|
57
|
+
Args:
|
|
58
|
+
callback (callable, optional): Function called when the event is fired.
|
|
59
|
+
The callback receives (params: audioListenerWillBeDestroyedEvent, session_id: Optional[str]).
|
|
60
|
+
"""
|
|
61
|
+
self.client.on('WebAudio.audioListenerWillBeDestroyed', callback)
|
|
62
|
+
def on_audio_node_created(self, callback: Callable[[audioNodeCreatedEvent,Optional[str]], None]=None) -> None:
|
|
63
|
+
"""
|
|
64
|
+
Notifies that a new AudioNode has been created.
|
|
65
|
+
Args:
|
|
66
|
+
callback (callable, optional): Function called when the event is fired.
|
|
67
|
+
The callback receives (params: audioNodeCreatedEvent, session_id: Optional[str]).
|
|
68
|
+
"""
|
|
69
|
+
self.client.on('WebAudio.audioNodeCreated', callback)
|
|
70
|
+
def on_audio_node_will_be_destroyed(self, callback: Callable[[audioNodeWillBeDestroyedEvent,Optional[str]], None]=None) -> None:
|
|
71
|
+
"""
|
|
72
|
+
Notifies that an existing AudioNode has been destroyed.
|
|
73
|
+
Args:
|
|
74
|
+
callback (callable, optional): Function called when the event is fired.
|
|
75
|
+
The callback receives (params: audioNodeWillBeDestroyedEvent, session_id: Optional[str]).
|
|
76
|
+
"""
|
|
77
|
+
self.client.on('WebAudio.audioNodeWillBeDestroyed', callback)
|
|
78
|
+
def on_audio_param_created(self, callback: Callable[[audioParamCreatedEvent,Optional[str]], None]=None) -> None:
|
|
79
|
+
"""
|
|
80
|
+
Notifies that a new AudioParam has been created.
|
|
81
|
+
Args:
|
|
82
|
+
callback (callable, optional): Function called when the event is fired.
|
|
83
|
+
The callback receives (params: audioParamCreatedEvent, session_id: Optional[str]).
|
|
84
|
+
"""
|
|
85
|
+
self.client.on('WebAudio.audioParamCreated', callback)
|
|
86
|
+
def on_audio_param_will_be_destroyed(self, callback: Callable[[audioParamWillBeDestroyedEvent,Optional[str]], None]=None) -> None:
|
|
87
|
+
"""
|
|
88
|
+
Notifies that an existing AudioParam has been destroyed.
|
|
89
|
+
Args:
|
|
90
|
+
callback (callable, optional): Function called when the event is fired.
|
|
91
|
+
The callback receives (params: audioParamWillBeDestroyedEvent, session_id: Optional[str]).
|
|
92
|
+
"""
|
|
93
|
+
self.client.on('WebAudio.audioParamWillBeDestroyed', callback)
|
|
94
|
+
def on_nodes_connected(self, callback: Callable[[nodesConnectedEvent,Optional[str]], None]=None) -> None:
|
|
95
|
+
"""
|
|
96
|
+
Notifies that two AudioNodes are connected.
|
|
97
|
+
Args:
|
|
98
|
+
callback (callable, optional): Function called when the event is fired.
|
|
99
|
+
The callback receives (params: nodesConnectedEvent, session_id: Optional[str]).
|
|
100
|
+
"""
|
|
101
|
+
self.client.on('WebAudio.nodesConnected', callback)
|
|
102
|
+
def on_nodes_disconnected(self, callback: Callable[[nodesDisconnectedEvent,Optional[str]], None]=None) -> None:
|
|
103
|
+
"""
|
|
104
|
+
Notifies that AudioNodes are disconnected. The destination can be null, and it means all the outgoing connections from the source are disconnected.
|
|
105
|
+
Args:
|
|
106
|
+
callback (callable, optional): Function called when the event is fired.
|
|
107
|
+
The callback receives (params: nodesDisconnectedEvent, session_id: Optional[str]).
|
|
108
|
+
"""
|
|
109
|
+
self.client.on('WebAudio.nodesDisconnected', callback)
|
|
110
|
+
def on_node_param_connected(self, callback: Callable[[nodeParamConnectedEvent,Optional[str]], None]=None) -> None:
|
|
111
|
+
"""
|
|
112
|
+
Notifies that an AudioNode is connected to an AudioParam.
|
|
113
|
+
Args:
|
|
114
|
+
callback (callable, optional): Function called when the event is fired.
|
|
115
|
+
The callback receives (params: nodeParamConnectedEvent, session_id: Optional[str]).
|
|
116
|
+
"""
|
|
117
|
+
self.client.on('WebAudio.nodeParamConnected', callback)
|
|
118
|
+
def on_node_param_disconnected(self, callback: Callable[[nodeParamDisconnectedEvent,Optional[str]], None]=None) -> None:
|
|
119
|
+
"""
|
|
120
|
+
Notifies that an AudioNode is disconnected to an AudioParam.
|
|
121
|
+
Args:
|
|
122
|
+
callback (callable, optional): Function called when the event is fired.
|
|
123
|
+
The callback receives (params: nodeParamDisconnectedEvent, session_id: Optional[str]).
|
|
124
|
+
"""
|
|
125
|
+
self.client.on('WebAudio.nodeParamDisconnected', callback)
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
"""CDP WebAudio Events"""
|
|
2
|
+
|
|
3
|
+
from typing import TypedDict, NotRequired, Required, Literal, Any, Dict, Union, Optional, List, Set, Tuple
|
|
4
|
+
|
|
5
|
+
from typing import TYPE_CHECKING
|
|
6
|
+
if TYPE_CHECKING:
|
|
7
|
+
from cdp.protocol.web_audio.types import AudioListener
|
|
8
|
+
from cdp.protocol.web_audio.types import AudioNode
|
|
9
|
+
from cdp.protocol.web_audio.types import AudioParam
|
|
10
|
+
from cdp.protocol.web_audio.types import BaseAudioContext
|
|
11
|
+
from cdp.protocol.web_audio.types import GraphObjectId
|
|
12
|
+
|
|
13
|
+
class contextCreatedEvent(TypedDict, total=True):
|
|
14
|
+
context: 'BaseAudioContext'
|
|
15
|
+
class contextWillBeDestroyedEvent(TypedDict, total=True):
|
|
16
|
+
contextId: 'GraphObjectId'
|
|
17
|
+
class contextChangedEvent(TypedDict, total=True):
|
|
18
|
+
context: 'BaseAudioContext'
|
|
19
|
+
class audioListenerCreatedEvent(TypedDict, total=True):
|
|
20
|
+
listener: 'AudioListener'
|
|
21
|
+
class audioListenerWillBeDestroyedEvent(TypedDict, total=True):
|
|
22
|
+
contextId: 'GraphObjectId'
|
|
23
|
+
listenerId: 'GraphObjectId'
|
|
24
|
+
class audioNodeCreatedEvent(TypedDict, total=True):
|
|
25
|
+
node: 'AudioNode'
|
|
26
|
+
class audioNodeWillBeDestroyedEvent(TypedDict, total=True):
|
|
27
|
+
contextId: 'GraphObjectId'
|
|
28
|
+
nodeId: 'GraphObjectId'
|
|
29
|
+
class audioParamCreatedEvent(TypedDict, total=True):
|
|
30
|
+
param: 'AudioParam'
|
|
31
|
+
class audioParamWillBeDestroyedEvent(TypedDict, total=True):
|
|
32
|
+
contextId: 'GraphObjectId'
|
|
33
|
+
nodeId: 'GraphObjectId'
|
|
34
|
+
paramId: 'GraphObjectId'
|
|
35
|
+
class nodesConnectedEvent(TypedDict, total=True):
|
|
36
|
+
contextId: 'GraphObjectId'
|
|
37
|
+
sourceId: 'GraphObjectId'
|
|
38
|
+
destinationId: 'GraphObjectId'
|
|
39
|
+
sourceOutputIndex: NotRequired['float']
|
|
40
|
+
destinationInputIndex: NotRequired['float']
|
|
41
|
+
class nodesDisconnectedEvent(TypedDict, total=True):
|
|
42
|
+
contextId: 'GraphObjectId'
|
|
43
|
+
sourceId: 'GraphObjectId'
|
|
44
|
+
destinationId: 'GraphObjectId'
|
|
45
|
+
sourceOutputIndex: NotRequired['float']
|
|
46
|
+
destinationInputIndex: NotRequired['float']
|
|
47
|
+
class nodeParamConnectedEvent(TypedDict, total=True):
|
|
48
|
+
contextId: 'GraphObjectId'
|
|
49
|
+
sourceId: 'GraphObjectId'
|
|
50
|
+
destinationId: 'GraphObjectId'
|
|
51
|
+
sourceOutputIndex: NotRequired['float']
|
|
52
|
+
class nodeParamDisconnectedEvent(TypedDict, total=True):
|
|
53
|
+
contextId: 'GraphObjectId'
|
|
54
|
+
sourceId: 'GraphObjectId'
|
|
55
|
+
destinationId: 'GraphObjectId'
|
|
56
|
+
sourceOutputIndex: NotRequired['float']
|
|
File without changes
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"""CDP WebAudio Domain Methods"""
|
|
2
|
+
from ..types import *
|
|
3
|
+
from .types import *
|
|
4
|
+
from typing import Optional, Dict, Any, Callable, TYPE_CHECKING
|
|
5
|
+
|
|
6
|
+
if TYPE_CHECKING:
|
|
7
|
+
from ....service import Client
|
|
8
|
+
|
|
9
|
+
class WebAudioMethods:
|
|
10
|
+
"""
|
|
11
|
+
Methods for the WebAudio domain.
|
|
12
|
+
"""
|
|
13
|
+
def __init__(self, client: "Client"):
|
|
14
|
+
"""
|
|
15
|
+
Initialize the WebAudio methods.
|
|
16
|
+
|
|
17
|
+
Args:
|
|
18
|
+
client ("Client"): The parent CDP client instance.
|
|
19
|
+
"""
|
|
20
|
+
self.client = client
|
|
21
|
+
|
|
22
|
+
async def enable(self, params: None=None,session_id: Optional[str] = None) -> Dict[str, Any]:
|
|
23
|
+
"""
|
|
24
|
+
Enables the WebAudio domain and starts sending context lifetime events.
|
|
25
|
+
Args:
|
|
26
|
+
params (None, optional): Parameters for the enable method.
|
|
27
|
+
session_id (str, optional): Target session ID for flat protocol usage.
|
|
28
|
+
|
|
29
|
+
Returns:
|
|
30
|
+
Dict[str, Any]: The result of the enable call.
|
|
31
|
+
"""
|
|
32
|
+
return await self.client.send(method="WebAudio.enable", params=params,session_id=session_id)
|
|
33
|
+
async def disable(self, params: None=None,session_id: Optional[str] = None) -> Dict[str, Any]:
|
|
34
|
+
"""
|
|
35
|
+
Disables the WebAudio domain.
|
|
36
|
+
Args:
|
|
37
|
+
params (None, optional): Parameters for the disable method.
|
|
38
|
+
session_id (str, optional): Target session ID for flat protocol usage.
|
|
39
|
+
|
|
40
|
+
Returns:
|
|
41
|
+
Dict[str, Any]: The result of the disable call.
|
|
42
|
+
"""
|
|
43
|
+
return await self.client.send(method="WebAudio.disable", params=params,session_id=session_id)
|
|
44
|
+
async def get_realtime_data(self, params: Optional[getRealtimeDataParameters]=None,session_id: Optional[str] = None) -> getRealtimeDataReturns:
|
|
45
|
+
"""
|
|
46
|
+
Fetch the realtime data from the registered contexts.
|
|
47
|
+
Args:
|
|
48
|
+
params (getRealtimeDataParameters, optional): Parameters for the getRealtimeData method.
|
|
49
|
+
session_id (str, optional): Target session ID for flat protocol usage.
|
|
50
|
+
|
|
51
|
+
Returns:
|
|
52
|
+
getRealtimeDataReturns: The result of the getRealtimeData call.
|
|
53
|
+
"""
|
|
54
|
+
return await self.client.send(method="WebAudio.getRealtimeData", params=params,session_id=session_id)
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"""CDP WebAudio Methods Types"""
|
|
2
|
+
|
|
3
|
+
from typing import TypedDict, NotRequired, Required, Literal, Any, Dict, Union, Optional, List, Set, Tuple
|
|
4
|
+
|
|
5
|
+
from typing import TYPE_CHECKING
|
|
6
|
+
if TYPE_CHECKING:
|
|
7
|
+
from cdp.protocol.web_audio.types import ContextRealtimeData
|
|
8
|
+
from cdp.protocol.web_audio.types import GraphObjectId
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class getRealtimeDataParameters(TypedDict, total=True):
|
|
13
|
+
contextId: 'GraphObjectId'
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
class getRealtimeDataReturns(TypedDict):
|
|
17
|
+
realtimeData: 'ContextRealtimeData'
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"""CDP WebAudio Domain"""
|
|
2
|
+
from typing import TYPE_CHECKING
|
|
3
|
+
from .methods.service import WebAudioMethods
|
|
4
|
+
from .events.service import WebAudioEvents
|
|
5
|
+
|
|
6
|
+
if TYPE_CHECKING:
|
|
7
|
+
from ...service import Client
|
|
8
|
+
|
|
9
|
+
class WebAudio(WebAudioMethods, WebAudioEvents):
|
|
10
|
+
"""
|
|
11
|
+
This domain allows inspection of Web Audio API. https://webaudio.github.io/web-audio-api/
|
|
12
|
+
"""
|
|
13
|
+
def __init__(self, client: "Client"):
|
|
14
|
+
"""
|
|
15
|
+
Initialize the WebAudio domain.
|
|
16
|
+
|
|
17
|
+
Args:
|
|
18
|
+
client ("Client"): The parent CDP client instance.
|
|
19
|
+
"""
|
|
20
|
+
WebAudioMethods.__init__(self, client)
|
|
21
|
+
WebAudioEvents.__init__(self, client)
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"""CDP WebAudio Types"""
|
|
2
|
+
|
|
3
|
+
from typing import TypedDict, NotRequired, Required, Literal, Any, Dict, Union, Optional, List, Set, Tuple
|
|
4
|
+
|
|
5
|
+
GraphObjectId = str
|
|
6
|
+
"""An unique ID for a graph object (AudioContext, AudioNode, AudioParam) in Web Audio API"""
|
|
7
|
+
ContextType = Literal['realtime','offline']
|
|
8
|
+
"""Enum of BaseAudioContext types"""
|
|
9
|
+
ContextState = Literal['suspended','running','closed','interrupted']
|
|
10
|
+
"""Enum of AudioContextState from the spec"""
|
|
11
|
+
NodeType = str
|
|
12
|
+
"""Enum of AudioNode types"""
|
|
13
|
+
ChannelCountMode = Literal['clamped-max','explicit','max']
|
|
14
|
+
"""Enum of AudioNode::ChannelCountMode from the spec"""
|
|
15
|
+
ChannelInterpretation = Literal['discrete','speakers']
|
|
16
|
+
"""Enum of AudioNode::ChannelInterpretation from the spec"""
|
|
17
|
+
ParamType = str
|
|
18
|
+
"""Enum of AudioParam types"""
|
|
19
|
+
AutomationRate = Literal['a-rate','k-rate']
|
|
20
|
+
"""Enum of AudioParam::AutomationRate from the spec"""
|
|
21
|
+
class ContextRealtimeData(TypedDict, total=True):
|
|
22
|
+
"""Fields in AudioContext that change in real-time."""
|
|
23
|
+
currentTime: 'float'
|
|
24
|
+
"""The current context time in second in BaseAudioContext."""
|
|
25
|
+
renderCapacity: 'float'
|
|
26
|
+
"""The time spent on rendering graph divided by render quantum duration, and multiplied by 100. 100 means the audio renderer reached the full capacity and glitch may occur."""
|
|
27
|
+
callbackIntervalMean: 'float'
|
|
28
|
+
"""A running mean of callback interval."""
|
|
29
|
+
callbackIntervalVariance: 'float'
|
|
30
|
+
"""A running variance of callback interval."""
|
|
31
|
+
class BaseAudioContext(TypedDict, total=True):
|
|
32
|
+
"""Protocol object for BaseAudioContext"""
|
|
33
|
+
contextId: 'GraphObjectId'
|
|
34
|
+
contextType: 'ContextType'
|
|
35
|
+
contextState: 'ContextState'
|
|
36
|
+
callbackBufferSize: 'float'
|
|
37
|
+
"""Platform-dependent callback buffer size."""
|
|
38
|
+
maxOutputChannelCount: 'float'
|
|
39
|
+
"""Number of output channels supported by audio hardware in use."""
|
|
40
|
+
sampleRate: 'float'
|
|
41
|
+
"""Context sample rate."""
|
|
42
|
+
realtimeData: NotRequired['ContextRealtimeData']
|
|
43
|
+
class AudioListener(TypedDict, total=True):
|
|
44
|
+
"""Protocol object for AudioListener"""
|
|
45
|
+
listenerId: 'GraphObjectId'
|
|
46
|
+
contextId: 'GraphObjectId'
|
|
47
|
+
class AudioNode(TypedDict, total=True):
|
|
48
|
+
"""Protocol object for AudioNode"""
|
|
49
|
+
nodeId: 'GraphObjectId'
|
|
50
|
+
contextId: 'GraphObjectId'
|
|
51
|
+
nodeType: 'NodeType'
|
|
52
|
+
numberOfInputs: 'float'
|
|
53
|
+
numberOfOutputs: 'float'
|
|
54
|
+
channelCount: 'float'
|
|
55
|
+
channelCountMode: 'ChannelCountMode'
|
|
56
|
+
channelInterpretation: 'ChannelInterpretation'
|
|
57
|
+
class AudioParam(TypedDict, total=True):
|
|
58
|
+
"""Protocol object for AudioParam"""
|
|
59
|
+
paramId: 'GraphObjectId'
|
|
60
|
+
nodeId: 'GraphObjectId'
|
|
61
|
+
contextId: 'GraphObjectId'
|
|
62
|
+
paramType: 'ParamType'
|
|
63
|
+
rate: 'AutomationRate'
|
|
64
|
+
defaultValue: 'float'
|
|
65
|
+
minValue: 'float'
|
|
66
|
+
maxValue: 'float'
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
"""CDP WebAuthn Domain Events"""
|
|
2
|
+
from ..types import *
|
|
3
|
+
from .types import *
|
|
4
|
+
from typing import Optional, Dict, Any, Callable, TYPE_CHECKING
|
|
5
|
+
|
|
6
|
+
if TYPE_CHECKING:
|
|
7
|
+
from ....service import Client
|
|
8
|
+
|
|
9
|
+
class WebAuthnEvents:
|
|
10
|
+
"""
|
|
11
|
+
Events for the WebAuthn domain.
|
|
12
|
+
"""
|
|
13
|
+
def __init__(self, client: "Client"):
|
|
14
|
+
"""
|
|
15
|
+
Initialize the WebAuthn events.
|
|
16
|
+
|
|
17
|
+
Args:
|
|
18
|
+
client ("Client"): The parent CDP client instance.
|
|
19
|
+
"""
|
|
20
|
+
self.client = client
|
|
21
|
+
|
|
22
|
+
def on_credential_added(self, callback: Callable[[credentialAddedEvent,Optional[str]], None]=None) -> None:
|
|
23
|
+
"""
|
|
24
|
+
Triggered when a credential is added to an authenticator.
|
|
25
|
+
Args:
|
|
26
|
+
callback (callable, optional): Function called when the event is fired.
|
|
27
|
+
The callback receives (params: credentialAddedEvent, session_id: Optional[str]).
|
|
28
|
+
"""
|
|
29
|
+
self.client.on('WebAuthn.credentialAdded', callback)
|
|
30
|
+
def on_credential_deleted(self, callback: Callable[[credentialDeletedEvent,Optional[str]], None]=None) -> None:
|
|
31
|
+
"""
|
|
32
|
+
Triggered when a credential is deleted, e.g. through PublicKeyCredential.signalUnknownCredential().
|
|
33
|
+
Args:
|
|
34
|
+
callback (callable, optional): Function called when the event is fired.
|
|
35
|
+
The callback receives (params: credentialDeletedEvent, session_id: Optional[str]).
|
|
36
|
+
"""
|
|
37
|
+
self.client.on('WebAuthn.credentialDeleted', callback)
|
|
38
|
+
def on_credential_updated(self, callback: Callable[[credentialUpdatedEvent,Optional[str]], None]=None) -> None:
|
|
39
|
+
"""
|
|
40
|
+
Triggered when a credential is updated, e.g. through PublicKeyCredential.signalCurrentUserDetails().
|
|
41
|
+
Args:
|
|
42
|
+
callback (callable, optional): Function called when the event is fired.
|
|
43
|
+
The callback receives (params: credentialUpdatedEvent, session_id: Optional[str]).
|
|
44
|
+
"""
|
|
45
|
+
self.client.on('WebAuthn.credentialUpdated', callback)
|
|
46
|
+
def on_credential_asserted(self, callback: Callable[[credentialAssertedEvent,Optional[str]], None]=None) -> None:
|
|
47
|
+
"""
|
|
48
|
+
Triggered when a credential is used in a webauthn assertion.
|
|
49
|
+
Args:
|
|
50
|
+
callback (callable, optional): Function called when the event is fired.
|
|
51
|
+
The callback receives (params: credentialAssertedEvent, session_id: Optional[str]).
|
|
52
|
+
"""
|
|
53
|
+
self.client.on('WebAuthn.credentialAsserted', callback)
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"""CDP WebAuthn Events"""
|
|
2
|
+
|
|
3
|
+
from typing import TypedDict, NotRequired, Required, Literal, Any, Dict, Union, Optional, List, Set, Tuple
|
|
4
|
+
|
|
5
|
+
from typing import TYPE_CHECKING
|
|
6
|
+
if TYPE_CHECKING:
|
|
7
|
+
from cdp.protocol.web_authn.types import AuthenticatorId
|
|
8
|
+
from cdp.protocol.web_authn.types import Credential
|
|
9
|
+
|
|
10
|
+
class credentialAddedEvent(TypedDict, total=True):
|
|
11
|
+
authenticatorId: 'AuthenticatorId'
|
|
12
|
+
credential: 'Credential'
|
|
13
|
+
class credentialDeletedEvent(TypedDict, total=True):
|
|
14
|
+
authenticatorId: 'AuthenticatorId'
|
|
15
|
+
credentialId: 'str'
|
|
16
|
+
class credentialUpdatedEvent(TypedDict, total=True):
|
|
17
|
+
authenticatorId: 'AuthenticatorId'
|
|
18
|
+
credential: 'Credential'
|
|
19
|
+
class credentialAssertedEvent(TypedDict, total=True):
|
|
20
|
+
authenticatorId: 'AuthenticatorId'
|
|
21
|
+
credential: 'Credential'
|
|
File without changes
|