-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinterface.py
59 lines (42 loc) · 1.11 KB
/
interface.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
from abc import abstractmethod
from typing import Any, Callable, Coroutine, Dict, Protocol, runtime_checkable
@runtime_checkable
class Translator(Protocol):
@abstractmethod
async def Do(self, text: str) -> Dict[str, str]:
pass
class Mouser(Protocol):
@abstractmethod
def listen(self, on_click: Callable[[], Coroutine[Any, Any, None]]) -> None:
pass
@abstractmethod
def close(self) -> None:
pass
class Notifyer(Protocol):
@abstractmethod
def send(self, title: str, body: str) -> None:
pass
class Clipboarder(Protocol):
@abstractmethod
def get(self) -> str:
pass
@abstractmethod
def close(self) -> None:
pass
class Comparable(Protocol):
@abstractmethod
def __eq__(self, __value) -> bool:
pass
class Ord(Comparable, Protocol):
@abstractmethod
def __le__(self, __value) -> bool:
pass
@abstractmethod
def __lt__(self, __value) -> bool:
pass
@abstractmethod
def __ge__(self, __value) -> bool:
pass
@abstractmethod
def __gt__(self, __value) -> bool:
pass