Browse Source

修复引用空间

master
hyh 4 months ago
parent
commit
24cd4a63d5
  1. BIN
      app/core/__pycache__/__init__.cpython-310.pyc
  2. BIN
      app/core/device/__pycache__/dispatcher.cpython-310.pyc
  3. 22
      app/core/device/dispatcher.py
  4. BIN
      app/schemas/__pycache__/adb.cpython-310.pyc
  5. BIN
      app/schemas/__pycache__/ssh.cpython-310.pyc
  6. BIN
      app/services/__pycache__/adb_service.cpython-310.pyc
  7. BIN
      app/services/__pycache__/at_service.cpython-310.pyc
  8. BIN
      app/services/__pycache__/ssh_service.cpython-310.pyc
  9. 2
      app/services/ssh_service.py
  10. 0
      logs/app.services.adb_service.log
  11. 0
      logs/app.services.ssh_service.log

BIN
app/core/__pycache__/__init__.cpython-310.pyc

Binary file not shown.

BIN
app/core/device/__pycache__/dispatcher.cpython-310.pyc

Binary file not shown.

22
app/core/device/dispatcher.py

@ -4,11 +4,11 @@
from typing import Dict, Any, Optional
import asyncio
from app.core.config import ProtocolType
from app.services.adb_service import ADBService
from app.services.ssh_service import SSHService
from app.services.at_service import ATService
from app.services.plnk_service import PLNKService
from app.services.atx_service import ATXService
from app.services.adb_service import AdbService
from app.services.ssh_service import SshService
from app.services.at_service import AtService
from app.services.plnk_service import PlnkService
from app.services.atx_service import AtxService
from app.utils.log import get_logger
logger = get_logger(__name__)
@ -22,13 +22,13 @@ class DeviceDispatcher:
def _initialize_services(self):
"""初始化所有协议服务"""
self._services[ProtocolType.ADB] = ADBService()
self._services[ProtocolType.SSH] = SSHService()
self._services[ProtocolType.AT] = ATService()
self._services[ProtocolType.PLNK] = PLNKService()
self._services[ProtocolType.ATX] = ATXService()
self._services[ProtocolType.ADB] = AdbService()
self._services[ProtocolType.SSH] = SshService()
self._services[ProtocolType.AT] = AtService()
self._services[ProtocolType.PLNK] = PlnkService()
self._services[ProtocolType.ATX] = AtxService()
# HDC服务可以复用ADB服务或单独实现
self._services[ProtocolType.HDC] = ADBService() # 暂时复用ADB服务
self._services[ProtocolType.HDC] = AdbService() # 暂时复用ADB服务
def get_service(self, protocol_type: str) -> Optional[Any]:
"""获取指定协议的服务实例"""

BIN
app/schemas/__pycache__/adb.cpython-310.pyc

Binary file not shown.

BIN
app/schemas/__pycache__/ssh.cpython-310.pyc

Binary file not shown.

BIN
app/services/__pycache__/adb_service.cpython-310.pyc

Binary file not shown.

BIN
app/services/__pycache__/at_service.cpython-310.pyc

Binary file not shown.

BIN
app/services/__pycache__/ssh_service.cpython-310.pyc

Binary file not shown.

2
app/services/ssh_service.py

@ -8,7 +8,7 @@ from app.utils.log import get_logger
logger = get_logger(__name__)
class SSHService:
class SshService:
"""SSH服务类 - 实现SSH协议相关操作"""
def __init__(self):

0
logs/app.services.adb_service.log

0
logs/app.services.ssh_service.log

Loading…
Cancel
Save